The Referer
request header contains the address of the previous web page from which a link to the currently requested page was followed. The Referer
header allows servers to identify where people are visiting them from and may use that data for analytics, logging, or optimized caching, for example.
Important: Although this header has many innocent uses it can have undesirable consequences for user security and privacy. See Referer header: privacy and security concerns for more information and mitigations.
Note that referer is actually a misspelling of the word "referrer". See HTTP referer on Wikipedia for more details.
A Referer
header is not sent by browsers if:
Header type | Request header |
---|---|
Forbidden header name | yes |
Referer: <url>
Referer: https://developer.mozilla.org/en-US/docs/Web/JavaScript
Specification | Title |
---|---|
RFC 7231, section 5.5.2: Referer | Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content |
Desktop | ||||||
---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | |
Basic support | Yes | Yes | Yes | Yes | Yes | Yes |
Mobile | |||||||
---|---|---|---|---|---|---|---|
Android webview | Chrome for Android | Edge Mobile | Firefox for Android | Opera for Android | iOS Safari | Samsung Internet | |
Basic support | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Referer