418

I'm a teapot

4xx Client Error

ELI5

I'm a teapot, not a coffee maker! This is an April Fools' joke code - don't use it in real APIs.

Server perspective

Treat 418 as an educational or playful status, not a production API contract.

When to use

  • Use 418 only for demos, jokes, or explicit non-production easter eggs
  • Remember that modern HTTP reserves 418 without giving it normal application semantics
  • Easter eggs in development environments
  • Demonstrating HTTP status codes
  • April Fools' Day jokes
  • Educational purposes only

How to respond

  • If you expose 418 at all, make sure product teams understand it is intentionally nonstandard
  • Prefer defined 4xx codes for real client errors

Headers to consider

  • No status-specific header is required; still send normal HTTP metadata such as Content-Type, caching, or tracing headers when they help the client.

Response body

  • No production API should depend on a 418 body contract; use it only for intentional demos or jokes.

Server-side pitfalls

  • Do not build real API error handling around 418
  • Do not assume generic tooling or clients will treat 418 consistently
  • Production APIs
  • Any serious application
  • When you need meaningful error responses

Examples

Coffee brewing request

Request:BREW https://api.example.test/coffee
Response:418 I'm a teapot # Headers Content-Type: application/json # Body { "error": "teapot" }

Server is a teapot and cannot brew coffee

References

Related Status Codes