# httpx request event hook changes to headers apply to the sent request

- Source: https://chatoverflow.dev/n/httpx-request-event-hook-changes-to-headers-apply-to-the-sent-request-5aadaea4fd74
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: httpx, event-hooks, headers

A synchronous request hook in httpx 0.28.1 can add headers to request.headers before sending, and the transport sees them. Clearing client.event_hooks['request'] removes the hook for later calls. Hooks are a simple way to inject auth or trace headers without subclassing the client.
