# What changed in httpxy

> 50 changes in httpxy 0.2 to 0.5 from its official release notes, upgrade guides and advisories: 7 breaking, 14 new APIs and options. Each one cited. Sources checked 2026-10-18. HTML: https://unstale.sh/npm/httpxy/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## httpxy 0.5

### Breaking changes

- Forces connection: close on chunked upstream requests. (0.5.5) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.5)
- Reverts trailing slash preservation in joinURL. (0.5.3) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.3)
- ProxyServer and proxyFetch now share keep-alive HTTP and HTTPS agents, with 256 max sockets and 64 max free sockets; set agent: false to restore per-request connections. (0.5.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.0)

### New APIs and options

- Declare pathname on ProxyTargetDetailed so developers can use the field in typed code. (0.5.4) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.4)
- Error events forward the target URL as their 4th argument. (0.5.2) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.2)
- Adds the server listeningCallback API. (0.5.1) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.1)

### Performance

- ReadableStream and Blob request bodies are piped directly upstream instead of buffered; bodies are still buffered for 307/308 replay when followRedirects is enabled. (0.5.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.0)

### Fixes and other changes

- Retains the relative protocol in the redirect location header. (0.5.5) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.5)
- Preserve transfer-encoding on chunked DELETE and OPTIONS requests. (0.5.4) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.4)
- Hosts are derived from hostname for plain object targets, and IPv6 literals are bracketed. (0.5.2) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.2)
- The trailing slash is preserved when proxying a root path to a sub-path target. (0.5.2) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.2)
- Headers are no longer set to undefined values. (0.5.1) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.1)
- Uses `agents: false` for WebSocket upgrades. (0.5.1) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.1)
- Fixes HTTP/2 header merging to preserve the host override order. (0.5.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.0)
- Outgoing requests are destroyed when a readable request body stream errors. (0.5.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.5.0)

## httpxy 0.4

### Breaking changes

- The distribution is ESM-only, affecting how consumers load the package. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- The deprecated req.abort() API is removed. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- The deprecated aborted listener is removed. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)

### New APIs and options

- Listeners can now support HTTP/2. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include agent. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include changeOrigin. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include followRedirects. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include HTTPS. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include path merging. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include timeout. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyFetch options now include xfwd. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)

### Fixes and other changes

- Client disconnects emit econnreset. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- WebSocket proxying skips writes to a closed socket on a non-upgrade response. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Response stream errors are handled on failed WebSocket upgrades. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Synchronous exceptions in middleware passes are caught. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- The target URL query string is preserved during path merging. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- proxyUpgrade preserves the wss:// protocol and fixes error handling. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Redirect host rewriting now handles object targets. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Redirect rewriting now handles relative Location URLs and includes HTTP 303. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Invalid response header characters are handled gracefully, and empty header names are skipped. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Undefined target values no longer overwrite SSL options. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- The transfer-encoding header is stripped on 204 and 304 responses. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)
- Middleware no longer appends duplicate x-forwarded-* header values. (0.4.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.4.0)

## httpxy 0.3

### Breaking changes

- Removes support for the legacy Node Url API. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)

### New APIs and options

- A standalone proxyUpgrade utility is available for use. (0.3.1) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.1)
- Implements native followRedirects support for web-incoming requests. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Adds proxyFetch. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)

### Fixes and other changes

- Aborts the proxy request when the client disconnects. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Emits a proxy error when a listener exists and rejects only when the error is unhandled. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Destroys the request socket on timeout. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Preserves multiple consecutive slashes in the request URL. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Ensures the outgoing path has a leading slash. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)
- Handles client socket errors before the upstream upgrade. (0.3.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.3.0)

## httpxy 0.2

### Behavior and default changes

- The server event type map is now generic, allowing its event types to be customized. (0.2.1) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.2.1)

### Tooling

- Proxy server events are now typed, improving type information for developers working with them. (0.2.0) — [release notes](https://github.com/unjs/httpxy/releases/tag/v0.2.0)
