speeding up tor

4 November 2007 at 12:01 am (Firefox, Tor) (, , , , , )

The Noreply Wiki has a very useful guide on how to make Tor faster. I’m working with revision 37, currently the most recent revision of the guide.

I started with Procedure 1, and altered about:config like so:

network.http.keep-alive.timeout:600 (300ms default is OK usually, but 600 is better.)
network.http.max-persistent-connections-per-proxy:16 (Default is 4)
network.http.pipelining:true (Default- false. Some old HTTP/1.0 servers can't handle it.)
network.http.pipelining.maxrequests:8 (No default)
network.http.proxy.keep-alive:true (Default- true, but double check)
network.http.proxy.pipelining:true (Default- false)

I’m going to skip all the suggestions about Fasterfox, because I don’t trust it to behave properly and not leak around the proxy, and I need to work with a lot of dynamic content anyway, which Fasterfox obviously can’t prefetch. I’m on Linux so I’m going to skip everything else in Procedure 2.

Procedure 3 is where this gets interesting, and where we actually start to make Tor faster, as opposed to making torified applications faster. The suggestions here really make a lot of difference in speed. I haven’t done any technical measurements, but I can see the difference very clearly when I’m browsing. However, though I haven’t tested, I suspect that I may potentially be sacrificing some anonymity for the increased speed. The authors of the guide note this is a possibility.

So I’m going to make two torrc configuration files, and I’ll use one when I need the best security I can get, and the other when I want speed and can afford to potentially be vulnerable to profiling attacks. For example, when I’m only concerned about the destination website knowing my IP, I can opt for speed. When I’m concerned about Big Brother, I can opt for security. This is simple to accomplish. I’m going to use Vidalia to switch between the two when I need to.

Vidalia’s torrc is at $HOME/.vidalia/torrc and I made a copy of it, in the same directory, called torrc-speed. The old torrc is going to remain unaltered; its defaults are secure. In the new torrc-speed, I added these lines:

# Try for at most NUM seconds when building circuits. If the circuit isn't
# open in that time, give up on it. (Default: 1 minute.)
CircuitBuildTimeout 5
# Send a padding cell every N seconds to keep firewalls from closing our
# connections while Tor is not in use.
KeepalivePeriod 60
# Force Tor to consider whether to build a new circuit every NUM seconds.
NewCircuitPeriod 15
# How many entry guards should we keep at a time?
NumEntryGuards 8

CircuitBuildTimeout, KeepalivePeriod, and NewCircuitPeriod are part of Procedure 3. I also added NumEntryGuards and increased it to 8 (the default is 3) because I want to give my speedy Tor the chance to pick faster entry guards if the low CircuitBuildTimeout means that some entry guards cannot be used. I don’t know whether this is actually necessary, nor whether it potentially decreases anonymity, but I don’t much care in this configuration. Save the file.

Then I went to Vidalia’s “Settings” screen and unchecked “Start Tor when Vidalia starts”. Then I went to the Advanced tab and pointed Vidalia at the new torrc-speed file. Then started Tor and tested it out. Yes, noticeably faster.

So now when Vidalia starts, it doesn’t start Tor yet, giving me the chance to go to the Settings > Advanced tab and change configuration files, to either the security or the speed configuration, before actually starting Tor.



  1. Магазета | TOR-ускорение said,

    […] speeding up tor […]

  2. jc said,

    This didnt work at all for me. Do you have any other suggestions

    My tor bandwidth montior consistantly stays at 0.5KB/sec with occasional spikes to 5K/sec. Too slow to be usable by anyone.

    Should I be opening ports on my router or something?

    Know any Tor Alternatives.

    Please email me at jpcx01@gmail.com

  3. Tor? said,

    jc, have you looked into Jap (aka AN.ON, aka JonDo)? If simple HTTP anonymisation is all you require it might be just the ticket. Jap was *significantly* faster than Tor last time I compared, probably due in no small part to being HTTP/FTP only – so no torrent traffic etc.

    You’ll need flashblock/noscript/etc. just like when using Tor.


  4. maz3n said,

    I tried your speeding up method and it actually worked. Thank you

  5. MonthsForever said,

    i tried this out on osx. not sure where to add the lines in the new torrc file tho. can i just copy and paste anywhere?

  6. cleaner said,

    it does work much better this way, and thanks for mentioning other staff as well.

  7. to-me-or-not-to-me said,

    Hi, your blog rocks, thanks for your savvy infos.

    “CircuitBuildTimeout 5” is equivalent to “CircuitBuildTimeout 30”.

    CircuitBuildTimeout seems to be patched to +30 seconds as per latest tor.

    The torrc config file with “CircuitBuildTimeout 5” is readen by tor as CircuitBuildTimeout 30, as you can verify starting tor from a terminal:

    # tor -f /path-to-your-torrc
    “[warn] CircuitBuildTimeout option is too short; raising to 30 seconds.”

    A pity, as your trick could be good for a low-privacy/anonymity but really faster tor, at least to pick faster tor nodes for the first two of the three hops from each circuit.

    Anyway, if CircuitBuildTimeout is not set in torrc, default seems to be 60, so 30 is much better for a fast tor behavior if/when strong privacy/anonymity is not required.

    by to-me-or-not-to-me.

  8. zardosht said,

    Thax for tweak, but tor version doesn’t allow to modify the file torrc or change the path to torrc-speed in vidalia.

    when any sort of modification happen tor simply can’t start as it warned in torrc itself.

    any Idea?

  9. Jeff said,

    You can make this work if you compile tor from source. I have tor running smoking fast right now. You just have to change one line in the source code in config.c You have to set the minimum circuit build value from 30 seconds, down to 0.

    Just use find and search for 30. You will find it halfway down the page. Then compile.

  10. Sholone said,

    How can i make tor fast with proxifier cause over here in Nigeria I connect with a GSM service provider but the original speed is 197kbs but when i connect through Proxifier and Tor the speed is going to too slow. Please what can i do to make it very fast. Thanks

  11. AnonymouZ said,

  12. Privacy Solutions Part 8: The Best Anonymizer Available: Tor, the TorButton & TorBrowser — Technology Liberation Front said,

    […] Tor is slow, it can be improved mildly by changing a number of default configuration options. See here, here, here and […]

  13. Anonymous said,


  14. Dj said,

    Mine is very slow help

  15. gio said,

    what can i do
    to make tor
    faster??! . . . . ;-(

  16. loki said,

    i don’t know if it is worked?? because my previous speed is 5kbps now i made it to 40kbps but its not enough so slow??

  17. Ogie said,

    I can’t load a page because I only got 5kbps Bandwidth as indicated in the Tor Bandwidth usage monitor. Is there a way to increase the bandwidth I am getting here? TIA. I already added the script in my torrc but it’s still slow.

  18. assurance de credit namur said,

    I got this site from my pal who informed me about this website and now this time I am visiting this site and reading very informative articles
    or reviews here.

  19. northern virginia home remodeling said,

    Howdy! This is kind of off topic but I need some guidance from an established
    blog. Is it very difficult to set up your own blog?
    I’m not very techincal but I can figure things out pretty quick. I’m thinking
    about making my own but I’m not sure where to start. Do you have any points or suggestions? Thank you

  20. viagra said,

    Great work! This is the kind of information that are supposed to be shared around the
    net. Disgrace on the search engines for not positioning this publish higher!
    Come on over and visit my site . Thank you =)

  21. référencement naturel said,

    Have you ever considered about adding a little bit more than just your articles?

    I mean, what you say is fundamental and all. However imagine if
    you added some great pictures or video clips to give your posts more, “pop”!

    Your content is excellent but with pics and video clips,
    this site could definitely be one of the best in its field.
    Great blog!

  22. creation site marchand said,

    Very nice post. I just stumbled upon your blog and wished to say that
    I’ve truly enjoyed browsing your blog posts. After all I’ll be subscribing to your rss
    feed and I hope you write again very soon!

  23. cover photos said,

    Aw, this was a very good post. Taking the time and actual effort to create a good article… but what can I say… I put things
    off a lot and don’t seem to get anything done.

  24. gif said,

    Hello there, I discovered your website by means of Google
    even as searching for a related topic, your site came up, it looks great.
    I’ve bookmarked it in my google bookmarks.
    Hello there, just became alert to your weblog via Google, and found that it’s
    really informative. I am going to watch out for brussels.

    I will appreciate if you proceed this in future. Many other
    folks will probably be benefited from your writing.

  25. Royce said,

    Most inkjet printer manufacturers sell printers at the loss or break even point to encourage sales,
    counting on the sale of replacement cartridges to make profits over time.
    It is also a good idea to wipe the top of the cartridge by way of a tissue before you start.
    Congress in 1994, which required contractors
    of printing jobs for government forms and contracts in order
    to make use of vegetable-based inks whenever possible.

  26. Marth Mildenstein said,


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: