<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Leo Lin</title>
    <description>The latest articles on DEV Community by Leo Lin (@leolin_flaship).</description>
    <link>https://dev.to/leolin_flaship</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4240660%2Fd18c78bd-17d1-4973-b7c2-d85870807a98.png</url>
      <title>DEV Community: Leo Lin</title>
      <link>https://dev.to/leolin_flaship</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/leolin_flaship"/>
    <language>en</language>
    <item>
      <title>How to Use a Proxy in Go: net/http, HTTP_PROXY, and Why GOPROXY Is Something Else</title>
      <dc:creator>Leo Lin</dc:creator>
      <pubDate>Mon, 23 Nov 2026 16:12:02 +0000</pubDate>
      <link>https://dev.to/leolin_flaship/how-to-use-a-proxy-in-go-nethttp-httpproxy-and-why-goproxy-is-something-else-8o1</link>
      <guid>https://dev.to/leolin_flaship/how-to-use-a-proxy-in-go-nethttp-httpproxy-and-why-goproxy-is-something-else-8o1</guid>
      <description>&lt;p&gt;&lt;em&gt;By Leo Lin, Product Manager at FlashIP (&lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;https://www.flaship.com/&lt;/a&gt;), Singapore. Disclosure: I work on FlashIP.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Go has two settings with "proxy" in the name. They do different jobs, and people mix them up all the time. &lt;code&gt;HTTPS_PROXY&lt;/code&gt; is a network proxy that your traffic passes through. &lt;code&gt;GOPROXY&lt;/code&gt; is a module mirror that &lt;code&gt;go get&lt;/code&gt; downloads code from. If you're behind a corporate gateway and &lt;code&gt;go mod download&lt;/code&gt; times out, changing &lt;code&gt;GOPROXY&lt;/code&gt; won't help. If your company runs a private module mirror, setting &lt;code&gt;HTTPS_PROXY&lt;/code&gt; won't point Go at it.&lt;/p&gt;

&lt;p&gt;Below is how each one works, based on the official Go docs and a few tests I ran on Go 1.27 against a dead proxy at &lt;code&gt;127.0.0.1:9&lt;/code&gt;. Hostnames and credentials are placeholders.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. net/http reads HTTP_PROXY, HTTPS_PROXY and NO_PROXY
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;http.DefaultTransport&lt;/code&gt;, which &lt;code&gt;http.Get&lt;/code&gt; and &lt;code&gt;http.DefaultClient&lt;/code&gt; use, picks up its proxy from the environment through &lt;code&gt;http.ProxyFromEnvironment&lt;/code&gt;. It reads &lt;code&gt;HTTP_PROXY&lt;/code&gt;, &lt;code&gt;HTTPS_PROXY&lt;/code&gt; and &lt;code&gt;NO_PROXY&lt;/code&gt;, or their lowercase versions, and chooses the proxy by the request's scheme:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;HTTPS_PROXY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;http://user:pass@proxy.example.com:8080
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;HTTP_PROXY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;http://user:pass@proxy.example.com:8080
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;NO_PROXY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;localhost,127.0.0.1,.internal.example.com,10.0.0.0/8
go run .
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Some details that trip people up:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The scheme decides.&lt;/strong&gt; An &lt;code&gt;https://&lt;/code&gt; URL uses &lt;code&gt;HTTPS_PROXY&lt;/code&gt; only. In my test, setting only &lt;code&gt;HTTP_PROXY&lt;/code&gt; sent &lt;code&gt;https://example.com&lt;/code&gt; direct (200 OK). With &lt;code&gt;HTTPS_PROXY&lt;/code&gt; set, the same request failed with &lt;code&gt;proxyconnect tcp: ... connection refused&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The value&lt;/strong&gt; can be a full URL or just &lt;code&gt;host[:port]&lt;/code&gt;. With &lt;code&gt;host[:port]&lt;/code&gt;, Go assumes &lt;code&gt;http&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;localhost is never proxied.&lt;/strong&gt; &lt;code&gt;ProxyFromEnvironment&lt;/code&gt; returns no proxy when the request host is &lt;code&gt;localhost&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The environment is read once.&lt;/strong&gt; In my test, calling &lt;code&gt;os.Setenv("HTTPS_PROXY", ...)&lt;/code&gt; after the first request had no effect, and the second request still went direct. Set the variables before the process starts, or set the proxy in code (section 3).&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. NO_PROXY syntax in Go
&lt;/h2&gt;

&lt;p&gt;According to the &lt;code&gt;golang.org/x/net/http/httpproxy&lt;/code&gt; docs, &lt;code&gt;NO_PROXY&lt;/code&gt; is a comma-separated list. Each entry can be:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;an IP prefix (&lt;code&gt;1.2.3.4&lt;/code&gt;) or a CIDR block (&lt;code&gt;10.0.0.0/8&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;a domain name, which matches the name and all its subdomains (&lt;code&gt;example.com&lt;/code&gt; matches &lt;code&gt;example.com&lt;/code&gt; and &lt;code&gt;api.example.com&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;a domain with a leading dot, which matches subdomains only (&lt;code&gt;.example.com&lt;/code&gt; doesn't match &lt;code&gt;example.com&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;an IP or domain with a port (&lt;code&gt;1.2.3.4:80&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;*&lt;/code&gt;, which turns proxying off completely&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Parsing is best effort and &lt;strong&gt;errors are ignored&lt;/strong&gt;. A typo won't throw an error. Go just ignores that entry and proxies the request.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Set the proxy in code (including SOCKS5)
&lt;/h2&gt;

&lt;p&gt;To use a proxy that doesn't depend on the environment, set &lt;code&gt;Transport.Proxy&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="n"&gt;proxyURL&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;_&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;url&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Parse&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"http://user:pass@proxy.example.com:8080"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Client&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nc"&gt;Transport&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Transport&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nc"&gt;Proxy&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;ProxyURL&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;proxyURL&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"https://example.com"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;Transport.Proxy&lt;/code&gt; supports the &lt;code&gt;http&lt;/code&gt;, &lt;code&gt;https&lt;/code&gt;, &lt;code&gt;socks5&lt;/code&gt; and &lt;code&gt;socks5h&lt;/code&gt; schemes. If the scheme is empty, Go uses &lt;code&gt;http&lt;/code&gt;. Go treats &lt;code&gt;socks5&lt;/code&gt; the same as &lt;code&gt;socks5h&lt;/code&gt;. Username and password in the URL are sent in a &lt;code&gt;Proxy-Authorization&lt;/code&gt; header. If &lt;code&gt;Proxy&lt;/code&gt; is &lt;code&gt;nil&lt;/code&gt;, Go doesn't use a proxy. So a &lt;code&gt;Transport&lt;/code&gt; you build yourself without setting &lt;code&gt;Proxy&lt;/code&gt; ignores &lt;code&gt;HTTPS_PROXY&lt;/code&gt; entirely. To keep the environment behavior on a custom transport, set &lt;code&gt;Proxy: http.ProxyFromEnvironment&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;My test confirmed SOCKS5 works from both places: &lt;code&gt;http.ProxyURL&lt;/code&gt; with a &lt;code&gt;socks5://&lt;/code&gt; URL and &lt;code&gt;HTTPS_PROXY=socks5://127.0.0.1:9&lt;/code&gt; both tried the dead proxy and failed.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. GOPROXY is a module mirror, not a network proxy
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;GOPROXY&lt;/code&gt; tells the &lt;code&gt;go&lt;/code&gt; command where to download modules. Its default value is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;https://proxy.golang.org,direct
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;direct&lt;/code&gt; means fetch from the version control repository, &lt;code&gt;off&lt;/code&gt; means don't fetch at all, and the separator controls fallback. After a comma, Go tries the next entry only on a 404 or 410 response. After a pipe (&lt;code&gt;|&lt;/code&gt;), it tries the next entry on any error, timeouts included.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GOPRIVATE=*.corp.example.com&lt;/code&gt; lists module path patterns that should never be requested from a proxy. It's the default for both &lt;code&gt;GONOPROXY&lt;/code&gt; and &lt;code&gt;GONOSUMDB&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A private mirror can take credentials in the URL: &lt;code&gt;GOPROXY=https://user:pass@proxy.corp.example.com&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To save these settings, use &lt;code&gt;go env -w GOPROXY=...&lt;/code&gt;. It writes to a config file in your user config directory, and &lt;code&gt;GOENV&lt;/code&gt; changes where that file lives. &lt;code&gt;go env -w&lt;/code&gt; only accepts Go's own variables, though. &lt;code&gt;go env -w HTTPS_PROXY=...&lt;/code&gt; failed with &lt;code&gt;unknown go command variable HTTPS_PROXY&lt;/code&gt;, so the network proxy still belongs in your shell or service environment.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;go&lt;/code&gt; command does honor &lt;code&gt;HTTPS_PROXY&lt;/code&gt; when it talks to a module mirror. With a dead proxy in &lt;code&gt;HTTPS_PROXY&lt;/code&gt;, &lt;code&gt;go mod download&lt;/code&gt; failed with a &lt;code&gt;proxyconnect&lt;/code&gt; error against &lt;code&gt;proxy.golang.org&lt;/code&gt;. For &lt;code&gt;direct&lt;/code&gt; fetches Go runs &lt;code&gt;git&lt;/code&gt;, and Git has its own &lt;code&gt;http.proxy&lt;/code&gt; setting. Its docs describe that setting as overriding &lt;code&gt;http_proxy&lt;/code&gt;/&lt;code&gt;https_proxy&lt;/code&gt;/&lt;code&gt;all_proxy&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Quick triage
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;curl uses the proxy but your Go binary doesn't → check that &lt;code&gt;HTTPS_PROXY&lt;/code&gt; is set for the process, and that a custom &lt;code&gt;Transport&lt;/code&gt; sets &lt;code&gt;Proxy&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;An internal host still goes through the proxy → check &lt;code&gt;NO_PROXY&lt;/code&gt; for typos. Remember the leading-dot rule.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;go get&lt;/code&gt; is blocked by the network → set &lt;code&gt;HTTPS_PROXY&lt;/code&gt;, not &lt;code&gt;GOPROXY&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Private modules return 404/410 or fail checksum lookups → set &lt;code&gt;GOPRIVATE&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you're testing against an external proxy, FlashIP (&lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;https://www.flaship.com/&lt;/a&gt;) offers HTTP(S) and SOCKS5 endpoints with username:password or IP whitelist authentication. The URL formats above work for either type.&lt;/p&gt;

&lt;h2&gt;
  
  
  Sources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;net/http package docs: &lt;a href="https://pkg.go.dev/net/http" rel="noopener noreferrer"&gt;https://pkg.go.dev/net/http&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;httpproxy package (NO_PROXY rules): &lt;a href="https://pkg.go.dev/golang.org/x/net/http/httpproxy" rel="noopener noreferrer"&gt;https://pkg.go.dev/golang.org/x/net/http/httpproxy&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Go Modules Reference (GOPROXY, GOPRIVATE): &lt;a href="https://go.dev/ref/mod" rel="noopener noreferrer"&gt;https://go.dev/ref/mod&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;cmd/go (go env -w, GOENV): &lt;a href="https://pkg.go.dev/cmd/go" rel="noopener noreferrer"&gt;https://pkg.go.dev/cmd/go&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;git-config (http.proxy): &lt;a href="https://git-scm.com/docs/git-config" rel="noopener noreferrer"&gt;https://git-scm.com/docs/git-config&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>go</category>
      <category>proxy</category>
      <category>networking</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>How to Configure a Proxy for Docker: docker pull, docker build and Containers</title>
      <dc:creator>Leo Lin</dc:creator>
      <pubDate>Mon, 23 Nov 2026 16:03:12 +0000</pubDate>
      <link>https://dev.to/leolin_flaship/how-to-configure-a-proxy-for-docker-docker-pull-docker-build-and-containers-53p</link>
      <guid>https://dev.to/leolin_flaship/how-to-configure-a-proxy-for-docker-docker-pull-docker-build-and-containers-53p</guid>
      <description>&lt;p&gt;&lt;em&gt;By Leo Lin, Product Manager at FlashIP (&lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;https://www.flaship.com/&lt;/a&gt;), Singapore.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;"I set &lt;code&gt;HTTP_PROXY&lt;/code&gt; and &lt;code&gt;docker pull&lt;/code&gt; still times out." I hear some version of this every month, and the cause is almost always the same: Docker doesn't have one proxy setting. It has at least three, and each one covers a different part of the pipeline. Set the wrong one and nothing changes.&lt;/p&gt;

&lt;p&gt;Here's the map I use, with every setting checked against Docker's own documentation in November 2026.&lt;/p&gt;

&lt;h2&gt;
  
  
  The three places a proxy can live
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;The daemon (&lt;code&gt;dockerd&lt;/code&gt;).&lt;/strong&gt; This is what talks to Docker Hub and other registries. &lt;code&gt;docker pull&lt;/code&gt; goes through here, and so does fetching images from registries generally.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The client config (&lt;code&gt;~/.docker/config.json&lt;/code&gt;).&lt;/strong&gt; This doesn't proxy the CLI or the engine. It &lt;em&gt;injects&lt;/em&gt; proxy variables into new containers and builds.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Build arguments and container env vars.&lt;/strong&gt; Per-command overrides with &lt;code&gt;--build-arg&lt;/code&gt; and &lt;code&gt;--env&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If you remember one thing: pulls are a daemon problem, and &lt;code&gt;apt-get&lt;/code&gt; or &lt;code&gt;pip install&lt;/code&gt; inside a &lt;code&gt;RUN&lt;/code&gt; step is a build problem.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Fix &lt;code&gt;docker pull&lt;/code&gt;: configure the daemon
&lt;/h2&gt;

&lt;p&gt;On Docker Engine (Linux), the recommended way is &lt;code&gt;daemon.json&lt;/code&gt;, usually at &lt;code&gt;/etc/docker/daemon.json&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"proxies"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"http-proxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"https-proxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"no-proxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"*.test.example.com,.example.org,127.0.0.0/8"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then restart the daemon:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;sudo systemctl restart docker
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can also use the &lt;code&gt;--http-proxy&lt;/code&gt; / &lt;code&gt;--https-proxy&lt;/code&gt; flags on &lt;code&gt;dockerd&lt;/code&gt;, or environment variables in a systemd drop-in. Settings in the daemon config take precedence over environment variables. If you go the systemd route, create &lt;code&gt;/etc/systemd/system/docker.service.d/http-proxy.conf&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight ini"&gt;&lt;code&gt;&lt;span class="k"&gt;[Service]&lt;/span&gt;
&lt;span class="na"&gt;Environment&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"HTTP_PROXY=http://proxy.example.com:3128"&lt;/span&gt;
&lt;span class="na"&gt;Environment&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"HTTPS_PROXY=http://proxy.example.com:3128"&lt;/span&gt;
&lt;span class="na"&gt;Environment&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"NO_PROXY=localhost,127.0.0.1,docker-registry.example.com,.corp"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then reload and confirm it took:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;sudo systemctl daemon-reload
sudo systemctl restart docker
sudo systemctl show --property=Environment docker
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Two gotchas from the docs that catch people:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Special characters in a systemd value must be double-escaped with &lt;code&gt;%%&lt;/code&gt;.&lt;/strong&gt; A password containing &lt;code&gt;#&lt;/code&gt; becomes &lt;code&gt;%%23&lt;/code&gt;. If your proxy password has symbols and auth keeps failing, this is the first thing to check.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rootless Docker uses a different path:&lt;/strong&gt; &lt;code&gt;~/.config/systemd/user/docker.service.d/&lt;/code&gt;, and you run &lt;code&gt;systemctl --user&lt;/code&gt; without &lt;code&gt;sudo&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Docker Desktop users:&lt;/strong&gt; proxy settings in &lt;code&gt;daemon.json&lt;/code&gt; are ignored by Desktop. Use the Proxies section in Docker Desktop's settings instead. Desktop has a separate "Containers proxy" that &lt;code&gt;docker pull&lt;/code&gt; and Compose pulls always go through, so set that one if pulls are what's failing.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Fix &lt;code&gt;RUN apt-get&lt;/code&gt; and &lt;code&gt;pip install&lt;/code&gt; inside builds: the client config
&lt;/h2&gt;

&lt;p&gt;The daemon proxy is for the daemon's own registry traffic. Commands running inside your build steps read proxy variables from their environment, so for those, add a &lt;code&gt;proxies&lt;/code&gt; block to &lt;code&gt;~/.docker/config.json&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"proxies"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"default"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"httpProxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"httpsProxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"noProxy"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"localhost,127.0.0.1,.internal.example.com"&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Docker uses this to set &lt;code&gt;HTTP_PROXY&lt;/code&gt;/&lt;code&gt;http_proxy&lt;/code&gt;, &lt;code&gt;HTTPS_PROXY&lt;/code&gt;/&lt;code&gt;https_proxy&lt;/code&gt; and &lt;code&gt;NO_PROXY&lt;/code&gt;/&lt;code&gt;no_proxy&lt;/code&gt; (plus &lt;code&gt;ftpProxy&lt;/code&gt; and &lt;code&gt;allProxy&lt;/code&gt; if you add them) as environment variables and build arguments. No restart needed, but it only applies to &lt;em&gt;new&lt;/em&gt; containers and builds. Anything already running keeps its old environment.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;default&lt;/code&gt; key applies to every daemon the client connects to. If you talk to a remote daemon that shouldn't use the proxy, add a key with that daemon's address (for example &lt;code&gt;tcp://docker-daemon1.example.com&lt;/code&gt;) and override &lt;code&gt;noProxy&lt;/code&gt; there.&lt;/p&gt;

&lt;p&gt;Quick check that it works:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run --rm alpine sh -c &lt;span class="s1"&gt;'env | grep -i _proxy'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  3. One-off overrides from the command line
&lt;/h2&gt;

&lt;p&gt;For a single build or run, pass the values directly:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build --build-arg &lt;span class="nv"&gt;HTTPS_PROXY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt; .
docker run --env &lt;span class="nv"&gt;HTTPS_PROXY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"http://proxy.example.com:3128"&lt;/span&gt; redis
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;HTTP_PROXY&lt;/code&gt;, &lt;code&gt;HTTPS_PROXY&lt;/code&gt;, &lt;code&gt;FTP_PROXY&lt;/code&gt;, &lt;code&gt;NO_PROXY&lt;/code&gt; and &lt;code&gt;ALL_PROXY&lt;/code&gt; (and their lowercase forms) are predefined build args, so you don't need an &lt;code&gt;ARG&lt;/code&gt; line to use them.&lt;/p&gt;

&lt;h2&gt;
  
  
  Keep credentials out of your images
&lt;/h2&gt;

&lt;p&gt;This is the part I'd tape to the monitor.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Don't use &lt;code&gt;ENV&lt;/code&gt; for proxy settings in a Dockerfile.&lt;/strong&gt; Docker's docs say it plainly: use build arguments instead. &lt;code&gt;ENV&lt;/code&gt; bakes the proxy into the image, which breaks containers run elsewhere and can leak credentials.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Don't declare &lt;code&gt;ARG HTTP_PROXY&lt;/code&gt; unless you mean to.&lt;/strong&gt; By default, the predefined proxy args are kept out of &lt;code&gt;docker history&lt;/code&gt; and don't affect the build cache. Adding an explicit &lt;code&gt;ARG HTTP_PROXY&lt;/code&gt; line reverses that: the value shows up in history and changing it invalidates the cache.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Remember env vars are inspectable.&lt;/strong&gt; Docker warns that container environment variables are stored as plain text, can be read through the remote API, and can end up in an image via &lt;code&gt;docker commit&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That last point is why I prefer IP allowlisting for build servers when the provider supports it: no password in a URL means nothing to leak. &lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;FlashIP&lt;/a&gt;, for example, supports HTTP(S) and SOCKS5 and accepts either username:password or IP allowlist authentication, so a CI runner with a fixed egress IP can skip credentials entirely. If you must use a username and password, keep them in your CI secret store and pass them with &lt;code&gt;--build-arg&lt;/code&gt; at build time.&lt;/p&gt;

&lt;h2&gt;
  
  
  A 60-second triage
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;docker pull&lt;/code&gt; fails → daemon config (or Desktop's Containers proxy).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;RUN apt-get update&lt;/code&gt; fails, but pulls work → &lt;code&gt;~/.docker/config.json&lt;/code&gt; or &lt;code&gt;--build-arg&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Works locally, fails for an internal registry → add it to &lt;code&gt;no-proxy&lt;/code&gt; / &lt;code&gt;NO_PROXY&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Auth errors only under systemd → check the &lt;code&gt;%%&lt;/code&gt; escaping.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Get the right layer and most "Docker ignores my proxy" tickets close themselves.&lt;/p&gt;

</description>
      <category>docker</category>
      <category>devops</category>
      <category>proxy</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>How to Set Up Git and npm Behind a Proxy (Without Pasting Your Password Everywhere)</title>
      <dc:creator>Leo Lin</dc:creator>
      <pubDate>Mon, 23 Nov 2026 11:03:39 +0000</pubDate>
      <link>https://dev.to/leolin_flaship/how-to-set-up-git-and-npm-behind-a-proxy-without-pasting-your-password-everywhere-4648</link>
      <guid>https://dev.to/leolin_flaship/how-to-set-up-git-and-npm-behind-a-proxy-without-pasting-your-password-everywhere-4648</guid>
      <description>&lt;p&gt;&lt;em&gt;By Leo Lin, Product Manager at FlashIP (&lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;https://www.flaship.com/&lt;/a&gt;), Singapore.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Every few weeks someone sends me a message that starts with "the proxy works in my browser but not in the terminal." Nine times out of ten it's not the proxy. Git and npm each have their own proxy settings, they also read environment variables, and the two sources quietly fight each other. This is the checklist I use when setting up a laptop on a company network that forces outbound traffic through a proxy, or when a team wants CI jobs to fetch from a fixed egress IP that a partner has allow-listed.&lt;/p&gt;

&lt;h2&gt;
  
  
  First, decide where the setting should live
&lt;/h2&gt;

&lt;p&gt;There are three places a proxy can come from:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Environment variables&lt;/strong&gt; (&lt;code&gt;http_proxy&lt;/code&gt;, &lt;code&gt;https_proxy&lt;/code&gt;, &lt;code&gt;no_proxy&lt;/code&gt;, and their uppercase versions). Many tools read them, which is convenient and also the reason leftovers cause chaos.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Git config&lt;/strong&gt; (&lt;code&gt;~/.gitconfig&lt;/code&gt; or a repo's &lt;code&gt;.git/config&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;npm config&lt;/strong&gt; (&lt;code&gt;~/.npmrc&lt;/code&gt; or a project &lt;code&gt;.npmrc&lt;/code&gt;).&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;My rule: use environment variables on CI runners, where each job starts clean, and use tool-specific config on laptops, where you want predictable behaviour and an easy way to undo it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Git over HTTPS
&lt;/h2&gt;

&lt;p&gt;The basic setting is one line:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config --global http.proxy http://proxy.example.com:8080
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Git applies &lt;code&gt;http.proxy&lt;/code&gt; to both &lt;code&gt;http://&lt;/code&gt; and &lt;code&gt;https://&lt;/code&gt; remotes. If you only need the proxy for one host, say an external GitHub mirror while internal servers stay direct, scope it to a URL instead:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config --global http.https://github.com.proxy http://proxy.example.com:8080
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;About credentials.&lt;/strong&gt; You can write &lt;code&gt;http://user:pass@proxy.example.com:8080&lt;/code&gt;, but then your password sits in plain text in &lt;code&gt;.gitconfig&lt;/code&gt;, which often ends up in dotfile repos. Git's documentation describes a better option: give a user name without a password (&lt;code&gt;http://user@proxy.example.com:8080&lt;/code&gt;) and Git asks for the password through its normal credential system, so a credential helper can store it securely.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SOCKS5.&lt;/strong&gt; Git hands proxy strings to libcurl, so &lt;code&gt;socks5h://proxy.example.com:1080&lt;/code&gt; works too. The &lt;code&gt;h&lt;/code&gt; means the proxy resolves hostnames, which matters on networks where internal DNS can't see public hosts.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SSH remotes are different.&lt;/strong&gt; If your remote looks like &lt;code&gt;git@github.com:org/repo.git&lt;/code&gt;, &lt;code&gt;http.proxy&lt;/code&gt; does nothing. Either switch that remote to HTTPS or configure a &lt;code&gt;ProxyCommand&lt;/code&gt; in &lt;code&gt;~/.ssh/config&lt;/code&gt;. This one catches people constantly.&lt;/p&gt;

&lt;p&gt;To undo:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config --global --unset http.proxy
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  npm
&lt;/h2&gt;

&lt;p&gt;npm uses two separate keys, and forgetting the second one is the most common mistake I see:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm config &lt;span class="nb"&gt;set&lt;/span&gt; proxy http://proxy.example.com:8080
npm config &lt;span class="nb"&gt;set&lt;/span&gt; https-proxy http://proxy.example.com:8080
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The registry is HTTPS, so &lt;code&gt;https-proxy&lt;/code&gt; is the one that actually matters for most installs. Note that the value is usually still an &lt;code&gt;http://&lt;/code&gt; URL; it describes how you talk to the proxy, not the destination.&lt;/p&gt;

&lt;p&gt;If you run a private registry inside the network, keep it off the proxy:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm config &lt;span class="nb"&gt;set&lt;/span&gt; noproxy &lt;span class="s2"&gt;"localhost,127.0.0.1,.internal.example.com"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;npm also honours &lt;code&gt;HTTP_PROXY&lt;/code&gt; and &lt;code&gt;HTTPS_PROXY&lt;/code&gt; from the environment, so if your &lt;code&gt;.npmrc&lt;/code&gt; looks right but traffic still goes somewhere odd, check &lt;code&gt;env | grep -i proxy&lt;/code&gt; first.&lt;/p&gt;

&lt;h2&gt;
  
  
  Corporate TLS inspection: don't turn off verification
&lt;/h2&gt;

&lt;p&gt;Many company proxies decrypt and re-sign HTTPS traffic with an internal certificate authority. The symptom is &lt;code&gt;SELF_SIGNED_CERT_IN_CHAIN&lt;/code&gt; in npm or &lt;code&gt;SSL certificate problem&lt;/code&gt; in Git. The tempting fix, &lt;code&gt;strict-ssl=false&lt;/code&gt; or &lt;code&gt;http.sslVerify=false&lt;/code&gt;, disables protection for everything. Ask IT for the CA certificate and point the tools at it instead:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config --global http.sslCAInfo /path/to/company-ca.pem
npm config &lt;span class="nb"&gt;set&lt;/span&gt; cafile /path/to/company-ca.pem
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Check that it actually works
&lt;/h2&gt;

&lt;p&gt;Don't trust the config file, trust a request:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Git: verbose output shows the proxy connection&lt;/span&gt;
&lt;span class="nv"&gt;GIT_CURL_VERBOSE&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;1 git ls-remote https://github.com/git/git 2&lt;span class="o"&gt;&amp;gt;&amp;amp;&lt;/span&gt;1 &lt;span class="o"&gt;|&lt;/span&gt; grep -i proxy

&lt;span class="c"&gt;# npm: show effective settings, then make one real request&lt;/span&gt;
npm config list
npm view lodash version
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you're testing a fixed egress IP for an allow-list, also run &lt;code&gt;curl https://api.ipify.org&lt;/code&gt; with the same environment variables and confirm the address is the one you gave your partner.&lt;/p&gt;

&lt;h2&gt;
  
  
  Quick troubleshooting
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;407 Proxy Authentication Required:&lt;/strong&gt; wrong or missing credentials. Re-enter them, watch for special characters that need URL-encoding (&lt;code&gt;@&lt;/code&gt; becomes &lt;code&gt;%40&lt;/code&gt;), and check your plan still has traffic or time left.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Works in Git, fails in npm:&lt;/strong&gt; you set &lt;code&gt;proxy&lt;/code&gt; but not &lt;code&gt;https-proxy&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Works in the terminal, fails in CI:&lt;/strong&gt; the runner doesn't have your shell profile. Set the variables in the job definition.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Internal hosts time out:&lt;/strong&gt; add them to &lt;code&gt;no_proxy&lt;/code&gt; / &lt;code&gt;noproxy&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Random behaviour after switching networks:&lt;/strong&gt; remove stale settings with &lt;code&gt;git config --global --unset http.proxy&lt;/code&gt; and &lt;code&gt;npm config delete proxy&lt;/code&gt; / &lt;code&gt;npm config delete https-proxy&lt;/code&gt;, then reapply only what you need.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Picking a proxy for this
&lt;/h2&gt;

&lt;p&gt;For developer tooling, the checklist is short: the protocol your tools speak (HTTP(S) covers both Git and npm; SOCKS5 is a bonus for Git), the authentication you prefer, and whether you need a stable IP for allow-lists. FlashIP supports HTTP(S) and SOCKS5 with either username:password or IP whitelist authentication; details are on &lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;flaship.com&lt;/a&gt;. Whatever provider or corporate proxy you use, run the checks above before you blame the network.&lt;/p&gt;

&lt;p&gt;Disclosure: I work on FlashIP.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
## 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>git</category>
      <category>npm</category>
      <category>proxy</category>
      <category>devops</category>
    </item>
    <item>
      <title>How to Set Up a Proxy in Postman for API Testing (and Check It Actually Works)</title>
      <dc:creator>Leo Lin</dc:creator>
      <pubDate>Mon, 23 Nov 2026 10:56:48 +0000</pubDate>
      <link>https://dev.to/leolin_flaship/how-to-set-up-a-proxy-in-postman-for-api-testing-and-check-it-actually-works-5bnd</link>
      <guid>https://dev.to/leolin_flaship/how-to-set-up-a-proxy-in-postman-for-api-testing-and-check-it-actually-works-5bnd</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I'm Leo Lin, Product Manager at FlashIP (&lt;a href="https://www.flaship.com/" rel="noopener noreferrer"&gt;https://www.flaship.com/&lt;/a&gt;), a proxy service.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;A surprising number of "the proxy is broken" messages I see turn out to be Postman settings, not the proxy. Credentials in the wrong field, a leftover environment variable, or two proxy options switched on at once. This is the setup routine I walk people through. The menu names below come from Postman's own documentation (the current v12 docs, read in November 2026); if your version looks different, check their proxy page.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why you might want a proxy in Postman
&lt;/h2&gt;

&lt;p&gt;Most API testing doesn't need one. The cases where it helps are usually about location or network:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Checking that your own API returns the right currency, language or regional content to a visitor in another country.&lt;/li&gt;
&lt;li&gt;Reproducing a bug a customer reports from a specific region.&lt;/li&gt;
&lt;li&gt;Testing a partner API that only accepts calls from an allow-listed IP.&lt;/li&gt;
&lt;li&gt;Working inside a company network that requires all outbound traffic to go through a proxy.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If none of these apply, leave the proxy off.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 1: Know which of Postman's three proxy options you need
&lt;/h2&gt;

&lt;p&gt;Postman's docs describe three separate things, and mixing them up is the most common mistake:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Default proxy.&lt;/strong&gt; The desktop app uses your operating system's proxy by default. If that system proxy needs a username and password, you add them under "Default proxy configuration". This can't be set in the Postman web app.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use system proxy.&lt;/strong&gt; A toggle that sends your API requests through the HTTP or SOCKS proxy configured on your computer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use custom proxy configuration.&lt;/strong&gt; A proxy you enter directly in Postman, separate from your system settings.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For testing through a proxy provider, you almost always want option 3. One rule to remember: if both the system proxy and the custom proxy toggles are on, Postman uses the custom proxy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 2: Enter the custom proxy
&lt;/h2&gt;

&lt;p&gt;In the desktop app, open &lt;strong&gt;Settings&lt;/strong&gt; in the header, choose &lt;strong&gt;App settings&lt;/strong&gt;, then the &lt;strong&gt;Proxy&lt;/strong&gt; tab. Under "Proxy configurations for sending requests", turn on &lt;strong&gt;Use custom proxy configuration&lt;/strong&gt; and fill in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Use proxy for:&lt;/strong&gt; HTTP, HTTPS or both. Both are selected by default, which is usually what you want.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Proxy server:&lt;/strong&gt; choose the protocol from the dropdown. Postman lists HTTP, SOCKS5, SOCKS5H, SOCKS4 and SOCKS4A. Then enter the hostname or IP and the port. Don't type &lt;code&gt;http://&lt;/code&gt; or &lt;code&gt;socks5://&lt;/code&gt; in front of the hostname; the protocol comes from the dropdown.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Proxy auth:&lt;/strong&gt; turn this on if your proxy uses a username and password, and enter them here, not in the hostname field.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Proxy bypass:&lt;/strong&gt; a comma-separated list of hosts that should skip the proxy. I put &lt;code&gt;localhost&lt;/code&gt; and any internal staging hosts here so local requests don't wander out through a proxy in another country.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;One note on SOCKS: Postman only sends HTTP and HTTPS requests through a SOCKS proxy, so it is not a general tunnel for other protocols.&lt;/p&gt;

&lt;p&gt;If your provider offers IP allowlisting instead of passwords, you can leave Proxy auth off, but the public IP of the machine running Postman must be on the list first.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 3: Check that traffic really goes through the proxy
&lt;/h2&gt;

&lt;p&gt;Don't trust the settings screen. Trust a request:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;With the proxy off, send a GET request to any public "what is my IP" endpoint and note the IP and country.&lt;/li&gt;
&lt;li&gt;Turn the custom proxy on and send the same request. The IP should change, and the location should match what you asked the provider for.&lt;/li&gt;
&lt;li&gt;Now send one real request to the API you're testing and compare the response with the no-proxy version: currency, language, headers, status code.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I keep these three requests in a small Postman collection called "proxy sanity check" so I can rerun them whenever something feels off.&lt;/p&gt;

&lt;h2&gt;
  
  
  Troubleshooting: the usual suspects
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Settings seem ignored.&lt;/strong&gt; Check for &lt;code&gt;HTTP_PROXY&lt;/code&gt;, &lt;code&gt;HTTPS_PROXY&lt;/code&gt;, &lt;code&gt;http_proxy&lt;/code&gt; or &lt;code&gt;https_proxy&lt;/code&gt; environment variables. Postman's docs note that when these are set, it can use them and ignore the in-app proxy settings. Leftovers from another tool are a classic cause.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;407 Proxy Authentication Required.&lt;/strong&gt; The proxy rejected your credentials. Retype them in the Proxy auth fields, check for stray spaces, and confirm your plan still has traffic or time left.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Local requests break.&lt;/strong&gt; Add the host to Proxy bypass.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Wrong country.&lt;/strong&gt; Check the IP with more than one geolocation lookup; databases disagree more often than people expect.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  A note on responsible use
&lt;/h2&gt;

&lt;p&gt;A proxy in Postman is a testing tool. Use it on your own APIs, on APIs you have permission to call, and within each service's terms and local law. If an API rate-limits you, slow down rather than spreading requests across IPs.&lt;/p&gt;

&lt;p&gt;If you're choosing a provider for this kind of testing, the practical checklist is short: HTTP(S) or SOCKS5 support, the authentication method you need, and the locations you actually test. FlashIP supports HTTP(S) and SOCKS5 with username:password or IP allowlist authentication; whichever provider you pick, run the three-request check above before you rely on it.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>postman</category>
      <category>api</category>
      <category>testing</category>
    </item>
  </channel>
</rss>
