Skip to content
Tor Proxy for your App on Heroku
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Tor Proxy Buildpack for Heroku

This buildpack sets up a Tor Proxy for your app on Heroku.


1] Create a Heroku app as normal with the usual buildpacks.

2] Then, add this buildpack in your app (through the Heroku CLI):

$ heroku buildpacks:add

3] With this buildpack installed, Tor Proxy runs automatically on the port: 9050.

NOTE: Tor Proxy is a SOCKS-proxy and works with SOCKS-supporting applications.


You'll need to provide these as env variables (check this guide):

  • TOR_VERSION: The version of Tor to install (default: its latest version).
  • TOR_PROXY_PORT: The port to be used for the proxy server (default: 9050).
  • TOR_CONTROL_PORT: The port to be used for the control server (default: 9051).
  • TOR_CONTROL_PASS: The password for the control server (default: "torProxy@123").
  • TOR_CONF_FILE_URL: The configuration for Tor to follow (default: Tor's default torrc).

NOTE: TOR_PROXY_PORT, TOR_CONTROL_PORT, and TOR_CONTROL_PASS override any values you provide in the custom torrc file defined by the TOR_CONF_FILE_URL. If you need to provide the values for these three variables, provide them through env variables rather than your custom torrc.


  • Caches compilation
  • Verifies integrity (confirm yourself; it's provided as is without any warranty)
You can’t perform that action at this time.