How to change Firefox's referer header for all http requests

4

When making a request for (for example) http://example.com/foo/bar.baz, Firefox sends a referer header indicating which page I clicked a link from, or is loading a picture, etc. Eg:

Referer: http://somewhere.else.com/page.html

I would like it to send

Referer: http://example.com/

instead, ie, to just send the root page of the site it's requesting from. How can I accomplish this?

David X

Posted 2010-09-28T02:05:11.907

Reputation: 464

Answers

1

The Firefox add-on RefControl can do this.

It has an option to always replace the Referer with the host only (stripping of the URL path). So if the real Referer is http://example.com/foo/bar.html, it becomes http://example.com/.

unor

Posted 2010-09-28T02:05:11.907

Reputation: 2 749

The link is dead. – a3nm – 2020-02-17T08:15:23.443

This is almost exactly what I was looking for; thanks! – David X – 2013-04-25T12:07:06.553

3

network.http.sendRefererHeader is Firefox option to control Referer header.

There are also some extensions like refspoof or "No Referrer".

Casual Coder

Posted 2010-09-28T02:05:11.907

Reputation: 3 614

(Probably should have mentioned this in the question, but) I already know about sendRefererHeader, it keeps Firefox from sending any referer at all, whereas I want to send a fake one. Will look into those extensions though. – David X – 2010-09-28T07:27:22.223

If this is one-off you can use modify headers extension to set your own headers. Then your Referrer header will be always the same. But my understanding of question is that you want to change your referrer header dynamically per request. As far as I know there is no easy way to do this. – Casual Coder – 2010-09-28T07:53:21.713

coder, yeah, thats about right, I guess I'll have to write my own extention for it when I have some free time. – David X – 2010-09-28T23:13:50.100

0

I found FireFox RefControl plugin very easy and effective way to do this. Steps:

  1. Add the plugin https://addons.mozilla.org/en-US/firefox/addon/refcontrol/
  2. restart firefox
  3. top right side choose RefControl options from refcontrol tool.
  4. click Add Site button now add the site(host) and select custom and add your Request Header Referer url
  5. click Ok and enjoy.

Mohammad Azam

Posted 2010-09-28T02:05:11.907

Reputation: 1

0

This is an old question, and RefControl addon mentioned in existing answers never works anymore with Firefox Quantum.

An alternative is Referer Control addon that has a similar functionality.

bytebuster

Posted 2010-09-28T02:05:11.907

Reputation: 611