How to Set Up Proxies in Wget
Route Wget traffic through an authenticated proxy in a few lines. Copy the code below and swap in your credentials.
Quick answer
Set the proxy in the format http://user:pass@host:port (env var or --proxy-user/--proxy-password) and send your Wget request through it. Full code below.
Wget proxy example
export https_proxy="http://user:pass@host:port"
export http_proxy="http://user:pass@host:port"
wget https://httpbin.org/ip -O -
# Or inline without env vars:
wget -e use_proxy=yes \
--proxy-user=user --proxy-password=pass \
-e https_proxy=host:port https://httpbin.org/ip -O -Wget reads the http_proxy and https_proxy environment variables, which is the simplest way to route a one-off download through an authenticated proxy. When you cannot set env vars, pass --proxy-user and --proxy-password alongside -e https_proxy=host:port on the command line. Wget only speaks HTTP/HTTPS proxies (no SOCKS), so pair it with a tool like proxychains if you need a SOCKS5 exit for rotation.
Rotating proxies
Wget works cleanly with rotating backconnect endpoints — point it at a single gateway host and the provider rotates the exit IP for you.
Best proxies to use with Wget
Cheapest-Proxies.com EDITOR'S CHOICE
4.9Best overall value across every proxy type and use case · flexible pay-as-you-go plans
Visit Cheapest-Proxies.comBright Data
4.6Enterprise-grade proxy and web data platform · from ~$8-9/GB (residential, volume-dependent)
Read Bright Data reviewOxylabs
4.6Premium enterprise proxies and scraper APIs · from ~$8/GB (residential, volume-dependent)
Read Oxylabs reviewSmartproxy
4.5User-friendly proxies with excellent price-to-performance · from ~$3.50-7/GB (residential)
Read Smartproxy reviewOur #1 pick is a sponsored partner. Remaining providers are ranked editorially by rating and value.
Frequently Asked Questions
Does Wget support authenticated proxies?
Yes. Provide the username and password (as a URL or separate fields) and Wget handles the auth handshake.
Can Wget rotate proxies automatically?
Yes — point it at a rotating backconnect endpoint and the provider rotates IPs for you.
What proxies work best with Wget?
Residential or rotating proxies from a reliable provider give the best success rate for CLI projects.
How do I add a proxy in Wget?
Supply the proxy as http://user:pass@host:port (env var or --proxy-user/--proxy-password) and pass it to Wget as shown in the code above.
Related Guides
Best proxies for Wget
We compared 40+ providers on price, coverage, and reliability — this one offered the best overall value.
Visit Cheapest-Proxies.com