Configuring curl and wget commands to use Proxy Servers

For proxy testing, use the following curl commands:

For username/password authentication:

 

curl -x http://username:password@proxy_host:proxy_port https://example.com

 

Example:

 

curl -x http://testuser:yourpassword@shp-testuser-uk-v00001.tp-ns.com:27281 https://ifconfig.info

 

Replace username, password, proxy_host, and proxy_port with your actual proxy credentials and server details.

 

For static IP authentication:

 

curl -x http://proxy_host:proxy_port https://example.com

 

Example:

curl -x http://shp-testuser-uk-v00001.tp-ns.com:27281 https://ifconfig.info

 

Use these commands to verify your proxy connection and ensure your requests are routed through the proxy server.

 

For proxy testing, use the following wget commands:

 

For username/password authentication:

 

wget -q --proxy-user=username --proxy-password=password -e use_proxy=yes -e http_proxy=http://proxy_host:proxy_port -O - http://ipinfo.io

 

Example:

 

wget -q --proxy-user=testuser --proxy-password=yourpassword -e use_proxy=yes -e http_proxy=http://shp-testuser-uk-v00001.tp-ns.com:27281 -O - http://ipinfo.io

 

Replace username, password, proxy_host, and proxy_port with your actual proxy credentials and server details.

 

For static IP authentication:

 

wget -q -e use_proxy=yes -e http_proxy=http://proxy_host:proxy_port -O - http://ipinfo.io

 

Example:

 

wget -q -e use_proxy=yes -e http_proxy=http://shp-testuser-uk-v00001.tp-ns.com:27281 -O - http://ipinfo.io

 

Use these commands to verify your proxy connection and ensure your requests are routed through the proxy server.

  • curl
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Configure Opera to Use a Proxy Server

All of our Proxy Server configuration settings can now be found here:   How To Set Up A Proxy...

Configure Microsoft Edge to Use a Proxy Server

All of our Proxy Server configuration settings can now be found here:   How To Set Up A Proxy...

Configuring PHP to use Proxy Servers

If you have a script that needs to send traffic via a Proxy Server, one of the best options is to...

Configure Google Chrome to Use a Proxy Server

All of our Proxy Server configuration settings can now be found here:   How To Set Up A Proxy...

Configure Market Samurai to Use Proxy Servers

This solution has been tested for WebHarvy (v3.4.0.119) To add your Trusted Proxies proxy...