← Back to headers
HTTP Header
DNT
RequestExpresses the user's tracking preference.
HTTP header reference, syntax, examples, and developer usage.
What is the DNT header?
The DNT HTTP header is used to transmit metadata between a client and server as part of HTTP requests or responses.
HTTP headers define how content should be interpreted, cached, authenticated, secured, or processed by browsers and APIs.
Direction
This is a request header sent by the client to the server.
Syntax
DNT: 0 | 1
Example
DNT: 1
Common use cases
- Signaling opt-out from tracking
- Communicating privacy preferences
Common mistakes
- Using the header in the wrong request or response context
- Sending invalid header values
- Incorrect header syntax
- Assuming the header automatically changes server behaviour
Practical developer insight
DNT was never widely enforced and has been deprecated in most browsers. It has largely been replaced by Global Privacy Control (Sec-GPC). The absence of the header means no preference expressed — not the same as DNT: 0.