What is Error 407?

HTTP 407 Proxy Authentication Required. Proxy server rejects request because auth credentials missing, invalid, or expired. Common with datacenter proxies (strict auth), less common with residential (IP whitelist).

1. Add Proxy Authorization Header

Format: Proxy-Authorization: Basic base64(user:pass)

2. Verify Credentials

Check username/password. Case-sensitive. Verify expiry date with proxy provider.

3. Rotate to New IP

Current IP blacklisted. Request fresh IP pool. If sticky IP, ask provider to refresh.

4. Update User-Agent

Some proxies reject suspicious UAs. Add: User-Agent: Mozilla/5.0

5. Use CONNECT Tunnel

For HTTPS, establish CONNECT tunnel first, then send request. Some proxies require this.

Other fixes: Check IP whitelist, use Digest auth, retry with backoff, contact provider support, verify proxy port (8080 vs 3128).