404 Not Found

The most famous error on the internet, and the one most often mistaken for a site being down. A 404 means the server is working perfectly and the thing you asked for is not there.

404 Not Found

The short version

  • A 404 proves the server is up. A dead server cannot tell you a page is missing.
  • Site-wide 404s after a deploy are a routing failure, and that is a real outage.
  • A soft 404 returns a 200 status with a not-found page, which is worse than a real 404.
  • For visitors, the fix is almost always the URL rather than anything technical.

There is something slightly absurd about 404 being the error everybody knows, because it is the one that tells you the least about anything being wrong. A server that returns a 404 is alive, connected, correctly configured and answering requests. It has looked for what you asked for and it is not there.

That makes 404 the opposite of an outage. It is proof of life.

What produces one

  • A typo. The most common cause by an enormous margin.
  • A page that used to exist. Content deleted, a site restructured, a product discontinued. The link still exists somewhere; the page does not.
  • A link that was always wrong. Someone published a URL with a trailing bracket, a truncated path, or a copy-paste error.
  • Case sensitivity. Most web servers treat /About and /about as different paths. This catches people constantly.
  • Content that has moved without a redirect. A site migration where old URLs were not mapped to new ones.
  • Region or account gating. Some services return 404 rather than 403 for content you are not allowed to see, so that the existence of the content is not revealed.

When a 404 is a real problem

Three situations where a 404 does mean something is broken, and they are worth recognising because they look identical to an ordinary missing page.

Everything returns 404

If the home page and every other page on a site return 404, that is not a missing page - It is a routing failure. The server is running and has no idea how to map any URL to any content. Usual causes: A deploy that shipped without its routing configuration, a virtual host pointing at an empty directory, or a container serving the wrong application.

This is a genuine outage that presents as the most reassuring error code there is, which is why it sometimes goes unnoticed for longer than a 500 would.

The API starts 404ing

For a client application, a 404 on an endpoint that existed yesterday is as fatal as a 500. Version changes, renamed routes and misconfigured gateways all produce this, and the client usually handles it worse than it handles a server error because 404 is often coded as "no data" rather than "failure".

Soft 404s

The worst variant. The server returns a friendly "page not found" message with a 200 OK status. Humans see the right thing; every automated consumer sees a successful response containing content. Search engines index it, monitoring tools report the site as healthy, and link checkers report no broken links.

If you operate a site, this is the one to check for. A not-found page must return 404.

404 versus 403 versus 410

CodeMeaningImplication
404Not foundIt may never have existed; it may come back
403ForbiddenIt exists and you are not allowed it
410GoneIt existed, it is deliberately removed, it is not coming back

410 is underused. It tells search engines to drop the URL far faster than a 404 does, which is exactly what you want for content you have deliberately removed.

Note the privacy consideration that drives a lot of real-world behaviour: Returning 403 for a private resource confirms the resource exists. Services that care about this return 404 instead, which is why a private repository or a deleted social media post shows as not found rather than forbidden.

What to do as a visitor

  1. Check the URL. Trailing characters, missing segments, wrong case. This is the answer most of the time.
  2. Trim the path. Remove the last segment and try again, then the one before. You will usually land on a section page that links to what you wanted.
  3. Search the site. Either its own search or a site-restricted web search. Content that moved is usually findable by title.
  4. Try an archive. For content that is genuinely gone, the Internet Archive frequently has it.
  5. Check the home page. If that 404s too, you have found a real outage rather than a missing page.

If it is your site

404s are normal and a site with none is a site nobody links to. What matters is which ones and how many.

Watch for 404s with referrers - Those are real people following real links, and each is a redirect you should have created. 404s from crawlers hitting URLs that never existed are noise and can be ignored.

Redirect deliberately, not in bulk. Mapping every removed page to the home page is worse than letting them 404: It wastes the visitor's time and search engines treat it as a soft 404 anyway. Map to the closest genuine equivalent, or let it 404 honestly.

And make the 404 page useful. A search box, the main navigation and a few popular links turn a dead end into a recoverable moment, which is worth more than the joke most 404 pages settle for.

Questions people ask

Does a 404 error mean a website is down?

No - It means the opposite. A server that returns 404 is running, connected and answering requests; it has looked for the page you asked for and not found it. A site that is genuinely down cannot tell you anything is missing.

Why do I get a 404 on a link that worked before?

The page was deleted, moved without a redirect, or the site was restructured. Trimming the URL back a segment at a time usually lands you on a section page that links to wherever the content went; the Internet Archive often has genuinely deleted content.

What is a soft 404?

A page that tells a human it was not found while returning a 200 OK status to machines. Search engines index it, monitoring tools report the site as healthy and link checkers see no broken links. A not-found page should always return a real 404 status.

What is the difference between 404 and 403?

404 means not found; 403 means it exists but you are not allowed to see it. Many services deliberately return 404 for private content, because returning 403 would confirm that the resource exists.

Read next

403 Forbidden

What a 403 Forbidden error means, why VPNs and shared addresses trigger it, and how to tell an access rule from a bot filter.

Error codes explained4 min read

500 Internal Server Error

What a 500 Internal Server Error actually means, why it is always the server's fault, and the handful of cases where a visitor can work around it.

Error codes explained4 min read

Why websites go down

The real causes of website outages - Configuration pushes, BGP withdrawals, expired certificates and dependency cascades.

Website downtime5 min read

502 Bad Gateway

What a 502 Bad Gateway error means, why it is one of the most common outage errors, and why it usually clears within minutes.

Error codes explained4 min read