404 Not Found
4xx client error
The server can't find anything at the requested URL.
404 is the web's most familiar error: there is nothing at this URL, or the server won't say there is. It isn't necessarily permanent — the resource might exist later — which is what separates it from 410 Gone.
For APIs, a 404 should mean the route or the specific record doesn't exist, not that a search came back empty.
| Class | 4xx Client Error |
|---|---|
| Retry? | No — change the request first |
| Cacheable by default | Yes (heuristically, per RFC 9110) |
| Response body | Allowed |
| Defined in | RFC 9110 §15.5.5 — 404 Not Found |
HTTP/1.1 404 Not Found
Content-Type: application/json
Content-Length: 21
{"error":"Not Found"}Common causes
- A typo, a broken link, or a link to a page that moved without a redirect.
- Case-sensitive paths:
/Aboutand/aboutare different URLs on most servers. - A single-page app served without a fallback, so deep links 404 on refresh.
- A deploy that dropped a file or route.
- An API record that was deleted or never existed.
How to fix it
- Redirect moved pages to their new URLs with 301.
- For single-page apps, serve index.html for unknown routes and let the app render its own not-found view.
- Return a real 404 status for missing pages — a 'not found' page served with 200 is a soft 404 that search engines flag.
- Make the 404 page useful: a search box and links to popular pages.
Useful here: HTTP Status Checker
Send a 404 from your server
res.status(404).json({ error: "Not Found" });return Response.json({ error: "Not Found" }, { status: 404 });return {"error": "Not Found"}, 404http.Error(w, "Not Found", http.StatusNotFound)
return 404;
Check what a URL returns
Print just the status line from the command line, or check a whole list of URLs at once, with their response headers, in the HTTP Status Checker.
curl -sI https://example.com/your-path | head -n 1
Frequently asked questions
Do 404s hurt SEO?
Not in themselves — Google expects them for pages that don't exist. What hurts is internal links pointing at 404s, and important pages that 404 instead of redirecting.
404 vs 410?
404: not here, and it may or may not come back. 410: deliberately removed and not coming back. Google drops 410 URLs a little faster.
What is a soft 404?
A page that says 'not found' but returns 200, or that redirects every missing URL to the homepage. Search Console flags these because the status contradicts the content.