Weirdo
Search weird questions

Question

Web OdditiesSeptember 6, 2026

Why can a page that looks like 404 still be HTTP 200?

HTTP404Google Search

Details

Success is the request, not “this page exists”

What the page says is not the status code. MDN defines `200 OK` as a successful request. For GET, the server retrieved a resource and put it in the body. That resource can be a custom “not found” template and still be a success. `404 Not Found` is the code that means the server cannot find the requested resource. MDN treats a custom 404 page as something you show visitors — the status remains 404. Google Search Central is blunter: custom 404 pages exist only for users; they are useless to a search engine, so the server must return HTTP `404` or the page can be indexed. Serve the same HTML with `200`, and the protocol records a hit.2

Client-side routing, and the soft 404

Single-page apps often route in the browser. Google’s JavaScript SEO guide says that with client-side rendering and routing, meaningful HTTP status codes can be impossible or impractical: an unknown URL may still receive the app shell as `200`, then JavaScript paints “not found.” Their workarounds: redirect in JavaScript to a URL whose server responds `404` (for example `/not-found`), or add a `noindex` robots meta tag on the error view. Google calls a page that tells the user it does not exist while returning 200 a soft 404; empty pages and pages with no main content count too. Once the algorithms decide from the content that it is an error page, Search Console’s Page Indexing report shows a soft 404, and the URL is excluded from Search. If the content is gone, send `404` or `410`. If it moved, send `301`.3

Also Asked As

404 但是 200 · soft 404 · SPA 404 200 · 網址列成功但頁面找不到