Skip to content

too_many_headers

HTTP 431 · code too_many_headers · limit MaxHeaders

The request has more header fields than the server accepts.

Sent before routing when the number of header fields exceeds MaxHeaders (100 by default). Every field counts, so a thousand copies of one header are a thousand fields.

Send fewer headers. Large cookie jars are the usual cause.

Raise MaxHeaders in photon.Limits if legitimate clients need more.

{
"type": "https://photon.agenticmarket.dev/errors/too_many_headers",
"title": "the request has too many header fields",
"status": 431,
"code": "too_many_headers",
"limit": "MaxHeaders"
}

Match on the code field rather than on title, which is meant for people and may change. See all error codes.