< HTTP/1.1 418 I'm a teapot418 I'm a Teapot: Origin and Real-World Use
418 I'm a teapot comes from the 1998 April Fools RFC 2324. See why RFC 9110 reserves it, why Node and Go keep it, and why some sites return it to bots.
- Cacheable
- Only with explicit freshness
- Retry?
- No
- Usually sent by
- Joke endpoints; reserved by RFC 9110
- Spec
- RFC 2324 §2.3.2
On this page
TL;DR: 418 is a joke status code from an April Fools RFC (2324, 1998). RFC 9110 reserves it as unused, so no standard behaviour exists. When you hit it on a real site, a human or a bot filter deliberately chose it, usually to turn you away as an automated client.
Origin
RFC 2324 (1 April 1998) specified HTCPCP, a protocol for controlling coffee pots. It added methods BREW and WHEN, a coffee: URI scheme, and a status code: 418 I'm a teapot, to be returned by a teapot asked to brew coffee. RFC 7168 (1 April 2014) extended it to tea, adding a TEA method, a Safe request header and tea-specific behaviours.
BREW /pot-1 HTTP/1.1
Host: coffee.example.com
Content-Type: application/coffee-pot-command
start
HTTP/1.1 418 I'm a teapot
Content-Type: text/plain
Short and stout.
Why it is still in your stack
In 2017 there was a proposal to drop 418 from libraries. Developers objected (the “Save 418” campaign), and maintainers of Node.js, Go (http.StatusTeapot), Python and others kept it. RFC 9110 §15.5.19 then settled the matter by listing it as (Unused), which tells implementers the number is spent, not that it is meaningful.
Google keeps an Easter egg at google.com/teapot, and many frameworks use 418 in their test suites as a convenient “unusual 4xx” for checking that clients treat unknown codes in the 4xx class as client errors. The relevant rule is RFC 9110 §15: an unrecognised status code is treated like the x00 code of its class, so a client should handle an unknown 4xx as 400.
What it means when you actually see it
The site returned 418 deliberately. The three realistic cases:
- Bot or scraper blocking. Some sites and security layers reply 418 to traffic they have classified as automated: default library user agents (
python-requests/2.x,Go-http-client/1.1), data-centre IP ranges, requests missing typical browser headers, or TLS fingerprints that do not match a real browser. Use the response to find out who sent it: look at theServer,Via,Set-Cookie(vendor cookies) and the body. The code itself carries no information. - A developer’s placeholder. Some APIs return 418 for “I refuse to process this” without a better category. Read the body.
- A test or joke endpoint.
httpbin.org/status/418returns a teapot ASCII drawing.
curl -i https://httpbin.org/status/418
HTTP/2 418
x-more-info: http://tools.ietf.org/html/rfc2324
content-type: text/plain
-=[ teapot ]=-
_...._
.' _ _ `.
| ."` ^ `". _,
\_;`"---"`|//
| ;/
\_ _/
`"""`
If you control the server
Do not use 418 for real refusals. Proxies, CDNs, uptime monitors and SDKs have no defined behaviour for it, so they will not retry it, alert on it or cache it consistently. Use 403 for a refusal, 429 with Retry-After for throttling, and 451 for legal blocks. If you want the client to learn nothing, nginx’s 444 closes the connection with no response.
If you are the client
Check whether the same URL works in a browser. If it does, compare headers (User-Agent, Accept, Accept-Language) with a curl -v request. If the site’s terms permit automated access, look for an official API or contact the operator, rather than escalating through header spoofing.
Related
- 403 Forbidden: the real refusal code.
- 429 Too Many Requests: throttling.
- 444 Connection Closed Without Response: silent drop in nginx.
Frequently asked questions
What does HTTP 418 I'm a teapot mean?
By specification it means a teapot was asked to brew coffee, a joke defined in the April Fools RFC 2324 in 1998. In real traffic it means the site chose 418 on purpose, most often to reject a request it classified as a bot, or the developer is testing client error handling.
Why am I getting 418 when scraping a website?
Some sites and bot-protection layers return 418 to requests they fingerprint as automated, such as the default python-requests or curl user agent, a datacenter IP, or a missing header set. It is a policy choice by that site, not a standard behaviour. Check the response body and headers for the vendor.
Is 418 an official status code?
RFC 9110 lists 418 as (Unused) and reserves it so it will not be reassigned, which is also why it is not removed from implementations. It is registered with IANA, but no standard HTTP semantics use it.
Should I use 418 in my API?
Not for anything real. Clients, proxies and monitoring have no defined behaviour for it, so they cannot distinguish a block from a teapot joke. Use 403 for refused requests and 429 for throttling.
Is 418 retryable?
There is no standard guidance. If a site is returning it to your scraper, retrying with the same identity produces the same result, so back off and review whether the access is permitted.
Sources
Related
402 Payment Required
Reserved for future use in digital payment systems. Learn about this experimental status code and modern payment verification alternatives.
426 Upgrade Required
The server refuses to perform the request using the current protocol and requires the client to upgrade to a different protocol.
400 Bad Request
400 Bad Request means the server could not parse your request. Find which layer sent it, fix bad JSON and oversized cookies or headers, and reproduce with curl.
HTTP 404 Not Found: What It Means and How to Fix It
404 Not Found means no resource exists at that URL. Find which layer sent it, then fix routing, deploys, rewrites, CDN cache and soft 404s, with curl checks.