HTTP
HTTP 404Not Found
HTTP 404 Not Found means the server is reachable but has nothing at the requested URL. The page may have moved or been deleted, the link may be wrong, or a rewrite rule may be misrouting the request. It does not indicate whether the absence is temporary or permanent; 410 Gone says permanent.
What 404 means
The connection worked, DNS resolved, the server answered, and it has nothing to give for that path. The server may add a custom body (the site's "not found" page) but the status is what matters to browsers, crawlers and monitoring.
Common causes
| Cause | Typical fix |
|---|---|
| Page deleted or renamed without a redirect | Add a 301 to the replacement, or serve 410 |
| Typo in the link or URL | Correct the link |
Case mismatch (/About vs /about) on a Linux server | Normalise URLs; add a rewrite if needed |
Trailing slash policy (/page vs /page/) | Redirect one form to the other consistently |
| Rewrite rules or a front controller not routing the request | Check .htaccess / nginx try_files |
| Wrong document root or virtual host | Server configuration |
| Deployment missing files | Verify the build output |
| Hotlinked asset removed | Host assets yourself |
Serving a good 404 page
- Return the real 404 status (never 200 with a "not found" message).
- Keep the site's navigation and a search box.
- Suggest likely destinations for the URL pattern.
- Keep it light; broken-link crawlers hit it often.
Apache: ErrorDocument 404 /404.html. nginx: error_page 404 /404.html;. Static hosts usually pick up 404.html automatically.
Finding 404s on your own site
Server logs, Google Search Console's "Not found" report, and a crawler (Screaming Frog, a scripted curl loop) all list them. Prioritise URLs with inbound links or traffic, and redirect those to the closest equivalent page.
Verifying
curl -I https://example.com/missing-page/The status line shows 404. If it shows 200 for a page that displays "not found", you have a soft 404 to fix. See the curl record.
Frequently asked questions
How do I fix a 404 as a visitor?
Check the URL for typos and capitalisation (paths are case-sensitive on most servers). Remove the last path segment to find the parent page. Use the site's search. Try the Wayback Machine for content that has been removed.
Should I redirect all 404s to the homepage?
No. It hides genuine breakage, confuses users who expected specific content, and search engines treat it as a soft 404. Redirect only where a genuinely equivalent page exists; otherwise serve a helpful 404 page with search and navigation.
404 or 410?
410 Gone tells clients and search engines the removal is deliberate and permanent, which speeds de-indexing. 404 is fine when you do not know or do not care. Both are correct; 410 is a small optimisation.
Why does a page 404 for me but load for others?
Different DNS resolution during a migration (you reach the old or new server), a CDN edge with stale routing, or a language/region variant. See DNS propagation.