How to Set a Specific Country in a Tor Browser
How to Set a Specific Country in a Tor Browser
When you use Tor to browse the web, your connection to the site is passed through random IP addresses based in any number of countries. This is great for keeping your real location private, but unhelpful if you want to visit a website that only allows connections from a particular country. If you want the sites you browse to think you're connecting from a certain location, you can add custom entry and exit nodes to your configuration file. It's a better idea to use a VPN to fake your location, but Tor will work if you don't have one. This wikiHow teaches you how to set custom exit and entry nodes in the Tor web browser using Windows, macOS, and Linux.
Steps

Open Tor at least once. You'll need to run Tor at least once to create the file you'll be editing. Just double-click the Start Tor browser icon in the folder where you've installed Tor and click Connect at least one time. If you've already started Tor, close it—you'll need to make sure the app is closed so you can effectively edit the configuration file. Keep in mind that not all sites and regions permit traffic from Tor, so you may not be able to access all websites using the browser.

Open the Tor folder. If you're using Windows or Linux, the location varies depending on where you installed the app. On Linux you may try to use commands locate torrc and find / torrc. If you're using a Mac, you'll actually need to open a different folder: Windows and Linux: The default install location for Tor is the desktop on both operating systems. Double-click the Tor Browser folder to open it. Mac: Open Finder, press Command + Shift + G, and enter or paste this address into the field: ~/Library/Application Support/TorBrowser-Data . Click Go to open the folder.

Navigate to the "torrc" file. This is the configuration file you'll need to edit. To find it: Windows and Linux: Double-click the Browser folder, double-click the TorBrowser folder, double-click the Data folder, and then double-click the Tor folder. Mac: Just double-click the Tor folder.

Open the file called torrc in a text editor. To do this, double-click the file. If it doesn't automatically open a text editor, you'll be prompted to choose one (e.g., Notepad for Windows or TextEdit for macOS).

Add the EntryNodes line. Place your cursor below the last line of text in the document, then type in EntryNodes {} StrictNodes 1 and press Enter or Return to go to the next line. Doing this step may not be necessary if all you want to do is set a specific exit node, the one whose IP address will be shown to the services you connect to.

Add the ExitNodes line. Type in ExitNodes {} StrictNodes 1 onto the next line.

Find your entry and exit country codes. Go to https://www.iso.org/obp/ui/#search in your web browser and write down the 2-digit code for the country you're pretending to be in. You can add multiple countries if you'd like. For example, if you want your Tor browsing session to start in Canada and exit in Egypt, you would look for the "Canada" country code (ca) and the "Egypt" country code (eg). Not all countries have Tor entry and exit nodes. After finding a code, go to https://metrics.torproject.org/rs.html, type country:eg (replace eg with the country code you want to look up), and click Search to find out if Tor has any relays there.

Enter your entry and exit country codes. Type the code for the country in which you want your session to start in between the {} curly brackets to the right of the "EntryNodes" line, and then repeat with the exit country and the "ExitNodes" line. For example, to enter in Canada and exit in Egypt, your lines might look like this: EntryNodes {ca} StrictNodes 1 ExitNodes {eg} StrictNodes 1

Consider disabling strict nodes. The "StrictNodes 1" value means that Tor will not try to use countries other than those you've specified. However, it also means that if no nodes are available in the regions you entered, you won't be able to make the connection. You can replace StrictNodes 1 with StrictNodes 0 to ensure that Tor can still use other countries' codes if those specified aren't working.

Add multiple country options to a strict node. If you do want to keep strict nodes enabled for your entry and/or exit nodes, consider adding multiple countries rather than just using one country. You can add countries by adding more country codes inside of brackets, making sure to separate them with commas. For example, to add Canada, Egypt, and Turkey to the "ExitNodes" line, you would have the following line: ExitNodes {ca},{eg},{tr} StrictNodes 1 Make sure there are no spaces between bracketed countries.

Save and exit the file. If you're using Windows or macOS, just click File, select Save, and exit the app. Saving the file in Linux depends on which text editor you're using. If you're using a graphical text editor, you can usually just press Ctrl + S to save.

Open Tor and visit a website. Go to any website (e.g., https://www.wikihow.com/) in Tor, and then click the padlock icon on the address bar at the top of the browser. Now you'll see the entry node, the middle nodes, and the exit node, which should match what you entered into the file.

What's your reaction?

Comments

https://umatno.info/assets/images/user-avatar-s.jpg

0 comment

Write the first comment for this!