A proxy server is an intermediary server between your device and the internet that forwards your web requests using its own IP address, so websites see the proxy's IP instead of yours. It relays each response back to you, which lets you hide your IP address from the sites you visit. The HTTP standard (RFC 9110) defines a proxy as a message-forwarding agent chosen by the client, usually through local configuration such as browser or system settings, or a scraper's code.

How a Proxy Server Works

  1. Your app sends the request to the proxy instead of the website. For a plain HTTP page it sends the full URL; for an HTTPS site it asks the proxy to open a tunnel with CONNECT host:443.
  2. The proxy contacts the website from its own IP address.
  3. The website responds to the proxy, and the proxy passes the response back to your app.

Types of Proxy Servers

  • By direction: a forward proxy acts for the client; a reverse proxy acts for the website's servers and handles jobs such as load balancing and caching.
  • By IP source: residential, datacenter, ISP and mobile proxies differ in who the IP address is registered to.
  • By protocol: HTTP proxies handle web requests, while SOCKS5 proxies relay TCP and UDP traffic for any app that supports SOCKS.
  • By who uses the IP: shared proxies are used by several customers at once; private proxies by one.
  • By how the IP changes: a rotating proxy switches IPs; a static proxy keeps one.
  • By whether you chose it: an interception proxy, often called a transparent proxy, is not chosen by the client. The network sends traffic through it, according to RFC 9110.

What Proxy Servers Are Used For

  • Privacy: hiding your IP address from the sites you visit.
  • Web scraping: spreading requests across many IP addresses with IP rotation.
  • Location-specific results: seeing what users in another country or city see, known as geo-targeting.
  • Internet access for internal networks: Apache's docs describe giving internet access to internal clients that are otherwise restricted by a firewall.
  • Caching: storing and reusing content to reduce bandwidth for a group of users.

What Websites Can Still See

A proxy changes the IP address a site sees, but not everything else:

  • Proxy headers: proxies may add a Via header, and some add X-Forwarded-For, which can carry the original client IP.
  • Leaks: a DNS leak or WebRTC leak can expose your real IP even while your traffic goes through the proxy.
  • Your browser or script: browser fingerprinting and cookies can still identify you.

Benefits and Drawbacks of Proxy Servers

Benefits: a proxy hides your IP address from the sites you visit. It can cache frequently requested content to speed up responses, and it lets organizations filter and control web access.

Drawbacks: routing traffic through an extra server can add latency. How much depends largely on how far away and how busy the proxy server is. Most proxies don't encrypt traffic by default, unlike a VPN. The proxy operator can also see and log the traffic that passes through it, so it matters which provider you trust, especially with unknown or free proxies. MDN notes there are likely hundreds of thousands of open forward proxies on the internet.

Proxy Server vs. VPN

A VPN usually encrypts all of a device's traffic through one server, while a proxy routes only the apps set to use it. See VPN vs. Proxy for a full comparison.