Is there a technical requirement to serve 404 responses?

Is there a technical requirement (e.g., RFC) to serve a 404 response?

Or does some other problem emerge if requests not found are dropped or replies empty?


An HTTP server is required to reply with an HTTP response message. Every HTTP request returns a status code, see RFC 1945.

The 4xx/5xx codes are just the error codes that are usually displayed to the user.


RFC 7230 Hypertext Transfer Protocol (HTTP/1.1): Message Syntax and Routing (Standards Track)

Section 2.1

...

A server responds to a client's request by sending one or more HTTP response messages, each beginning with a status line that includes the protocol version, a success or error code, and textual reason phrase ...

According to this RFC, you can't simply drop the connection or send an empty reply.