418 I’m a teapot, explained
The most famous HTTP status code that isn’t really one: an April Fools’ joke from 1998 that was deployed so often the official HTTP specification had to fence it off.
On 1 April 1998, Larry Masinter published RFC 2324, the Hyper Text Coffee Pot Control Protocol (HTCPCP/1.0). It is a careful parody of how people were stretching HTTP to control everything, complete with a BREW method, a WHEN method (“Enough? Say WHEN.”) and a coffee: URI scheme. Section 2.3.2 added the line that outlived the joke:
Any attempt to brew coffee with a teapot should result in the error code “418 I’m a teapot”. The resulting entity body MAY be short and stout.
Why the real HTTP spec reserves it#
The joke escaped into real software, which created a real problem: a code that is widely deployed as a joke can’t safely be given a serious meaning later. So when the IETF consolidated HTTP semantics in RFC 9110, it gave 418 its own section, titled 418 (Unused). It says the code “has been deployed as a joke often enough for the code to be unusable for any future use,” and is therefore reserved in the IANA registry. It also leaves a door open: if the 4xx range is ever exhausted, 418 can be reassigned.
HTTP/1.1 418 I'm a teapot to reject a request your API doesn’t like
The real code for the situation: 400, 403, 422 or 429
RFC 9110 says a client that doesn’t recognise a status code must treat it as the x00 code of its class. Your clever 418 becomes a plain 400 to every client, and a mystery to whoever reads the logs.
The sequel: tea, officially#
Sixteen years later, on 1 April 2014, RFC 7168 extended the protocol for “Tea Efflux Appliances” (HTCPCP-TEA), because the original “does not allow for the brewing of tea, in all its variety.” It also clarified the teapot’s options: a tea-capable pot that can’t brew coffee may return 503 to mean coffee is temporarily unavailable, or 418 “to denote a more permanent indication that the pot is a teapot.”
What 418 teaches about real status codes#
- Codes are a contract. Clients, caches and crawlers act on the number, so a code’s meaning has to stay stable for decades.
- The class matters most. Unknown codes fall back to
x00of their class, which is why a wrong class does far more damage than an obscure specific code. - Jokes get deployed. Anything you ship, people will depend on. That’s true of status codes and of the famous software bugs that became permanent behaviour.
Frequently asked questions
Is 418 I'm a teapot an official HTTP status code?
Not in the usual sense. It was defined by RFC 2324, an April 1 joke RFC for the Hyper Text Coffee Pot Control Protocol. RFC 9110, the current HTTP semantics standard, lists 418 as (Unused) and reserves it in the IANA registry so it cannot be assigned to anything else for now.
Why didn't the IETF just delete 418?
RFC 9110 says the code has been deployed as a joke often enough to be unusable for any future use. Reassigning it would mean real clients could misread old joke responses, so it is reserved instead. The RFC adds that it could be reassigned if 4xx codes ever run out.
Should my API return 418?
No. Clients that do not recognise a code treat it as the x00 of its class, so a 418 is handled like 400 Bad Request, and nobody reading your logs will know what you meant. Use the real code for the situation, such as 400, 403, 422 or 429.
What does a 418 response body look like?
RFC 2324 says the resulting entity body "MAY be short and stout." That line, from the children's song, is the whole specification.
Sources
Every factual claim on this page links to one of these. Checked October 2026. See how we source.
- RFC 2324: Hyper Text Coffee Pot Control Protocol (HTCPCP/1.0) rfc-editor.org
- RFC 7168: HTCPCP for Tea Efflux Appliances (HTCPCP-TEA) rfc-editor.org
- RFC 9110: HTTP Semantics, Section 15.5.19 (418 Unused) rfc-editor.org
- RFC 9110: HTTP Semantics, Section 15 (Status Codes) rfc-editor.org
- IANA HTTP Status Code Registry iana.org