Back to Path
Beginner · 2 minModule 5 of 18
Request Headers
Request headers are sent by the client to give the server context about the user or the environment.
Interactive Protocol Simulation
Step 1 / 4
Step 1 of 4
User-Agent:Browser Info
Mozilla/5.0...
Accept:Preference
text/html
Host:Destination
example.com
Cookie:Identity
session_id=123
Worked example
Request
Host: developer.mozilla.org
User-Agent: Mozilla/5.0
Accept: text/htmlWithout the "Host" header, a modern server hosting multiple websites wouldn't know which one you want to visit!
Must-Know Request Headers
These headers are found in almost every request:
- Host — MANDATORY. The domain name of the server (e.g., google.com).
- Accept — The content types the client understands (e.g., text/html).
- Authorization — Used to send credentials like a password or token.
- Cookie — Sends previously stored small data back to the server.
Study kit
Module 5 of 18
Beginner · 2 min · 0 of 18 complete
Module status
Not completed yet
Notessaved locally+
Notes stay in this browser. They are not uploaded.
Suggest an editLearning graph
Prerequisites
Discussion
Loading discussion…
Sign in to ask a question.