`node-fetch` does not work behind a proxy
Author: deeprobinCreated Aug 23, 2023Updated Jan 31, 2026
Labelsbug
Reproduction
Steps to reproduce the behavior:
- Install some tooling which consumes the fetch api
- Go behind some corporate proxy
- Try to run
Expected behavior
If not explicitly specified, use of the system proxy.
Under Windows, for example, the proxy settings should be taken into account. With more priority, the environment variables HTTP_PROXY, HTTPS_PROXY & NO_PROXY should also be taken into account.
Screenshots
Your Environment
| software | version |
|---|---|
| node-fetch | ^3.3.1 |
| node | 18.15.0 |
| pnpm | 7.30.0 |
| Operating System | Microsoft Windows 10 Enterprise Version 22H2 (Build 19045.3208) |
Additional context
Source: node-fetch/node-fetch