Hi I'm doing some web development and wanted to be able to do some cross browser testing. Normally I would just point which ever browser I'm using at localhost and go from there.

Unfortunately Tor Browser seems to be unable to reach the address. I don't want to expose any unfinished work to the public internet and prefer the convenience of working locally. Any suggestions?

  • 1
    socks5 proxy localhost:9150 – EmmGold Apr 17 '18 at 13:30

You could set up an onion service with HiddenServiceAuthorizeClient, that would allow you, and only you, to access localhost resources through Tor Browser without any modifications or special settings. This is the least likely to fail catastrophically.

If and only if you are going to use it to view purely localhost content (e.g. you don't reference external resources on the site) then you might try this:

Set aside a distinct and clearly marked copy of Tor Browser then follow this guide to use Tor Browser with an upstream transproxy, this will make Tor Browser disable its own proxying and just connect directly. You can skip the bits about the control port and ignore the Tor Button errors since you're not using Tor at all.

I cannot stress enough just how important it is that you do not allow those environment variables to affect (infect?) any copy of Tor Browser you intend to use for actual browsing. Possibly you want to do this from a computer that is totally disconnected from the network, to be certain.


By far the easiest and safest is to start a local .onion service, then connect to it normally.

  1. Create an empty folder somewhere, e.g. C:/my/keys/test1

  2. Then add this to torrc:

     HiddenServiceDir C:/my/keys/test1
     HiddenServiceVersion 3
     HiddenServicePort 80

    On Windows, torrc is at %USERPROFILE%\Desktop\Tor Browser\Browser\TorBrowser\Data\Tor\

  3. Now restart your Tor Browser, and it'll create a file C:/my/keys/test1/hostname, which will contain the .onion address pointing to your localhost:80

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.