Step-by-step proxy setting for Linux

Comments: 0

A large number of operating systems are based on the Linux kernel. They are convenient and have many useful features, but they can not promise their users reliable data protection. If you want to secure your device and all your information, setting up a proxy server for Linux is a great solution.

By using a proxy, you will also hide your IP address, which will help you stay anonymous online and bypass regional blocking.

Video guide for setting up a proxy in Linux

How to set up a proxy on Linux

Configuration in Linux occurs through the command line. You can set up a proxy for the entire system or a specific program. We will tell you about each method.

Proxy setting for the OS:

  1. Find the Terminal application on your device and open it.
  2. 1:1.png

  3. Enter the command $ sudo nano /etc/environment.
  4. 2:1.png

  5. Below, enter the lines with the data of the proxy server (depending on the type of your proxy):
    • export http_proxy="http:// username:password@IP-address:port"
    • export https_proxy="https:// username:password@IP-address:port"
    • export socks_proxy="socks:// username:password@IP-address:port"
    • export ftp_proxy="ftp://usermane:password@IP-address:port;

    You can enter several proxies of different types at once (http, https, socks, or ftp).


  6. Close the Terminal and reboot your device.

Proxy settings for a specific program:

  1. Open the Terminal application once again.
  2. Enter the command with the name of the program for which you want to configure the proxy: $ sudo nano /etc/program_name/default (we will configure the proxy for Google Chrome).
  3. 2:2.png

  4. Below, enter a line with your proxy data in the same way as you did above:
  5. GOOGLE_CHROME="-proxy-server="[username]:[password]@ [IP-address]:[port-number]"


  6. Close the terminal and restart your computer. Done!

Now the operating system or a separate program on the device will work through a proxy with a new IP address.

How to check if the proxy is working

To make sure you have configured your proxy server correctly, open any browser and type in the search bar "Find out the IP address" or "What is my IP address" and select any site that you like. If the shown IP address matches that one of your proxy, then you've done the right thing!