To detect a soft 404, check what the page says about the resource you requested. If the target returns HTTP 200 and the main heading matches a known missing-page template, look for the section or resource identifier you expect to find. When that evidence is absent, hold the response out of your index and record it as a soft 404 candidate. A blank page, a generic homepage, and a valid empty result each need a different decision. Use a known-good URL and a missing-page control to test your rules before applying them to new pages.
Track the request and the document separately
A page can say “This guide does not exist” while the server sends HTTP 200. Google Search Central's soft 404 guidance describes this mismatch. When the target itself returns HTTP 404 or 410, the decision starts with the status. See the HTTP semantics standard for how those codes describe availability.
An extraction service adds another status. Its own HTTP response tells you whether the API answered. The reported target status describes what the service received from the source, when that field is available. After checking both, ask whether the returned content identifies the document you wanted. A guide that moves to a new path may still be usable if its final URL and content point to the same guide. A redirect ending at a generic homepage warrants an identity check, even when the homepage contains plenty of text.
Read the heading in context
Start with the page region where you expect the document. For a known documentation template, that might be the primary heading plus a section or resource identifier. Take missing-page phrases from approved examples of the actual template. A string search over the entire page would also match documentation that quotes its own error messages.
| What came back | What to do before indexing |
|---|---|
| HTTP 200, known missing-page heading, and no expected document markers | Hold as a soft 404 candidate. Record which template matched. |
| Target HTTP 404 or 410 | Hold under the observed HTTP status. |
| HTTP 200 and a shell where the main content should be | Check whether the expected body appears after JavaScript runs. |
| HTTP 200 on a different page with no matching subject | Hold for an identity check. Preserve the final URL. |
| HTTP 200 and a verified collection with zero items | Keep the empty result if its heading or identifier confirms the intended collection. |
If the raw response looks like an app shell, use the empty JavaScript shell checks to decide whether a render pass would answer the question. A heading that looks wrong in isolation may turn out to belong to an unfamiliar locale or a redesigned template. Keep the decision open when the page gives conflicting signals.
Test a known page and a missing-page control
Paste the Fetch documentation URL into the free URL-to-Markdown tool to see the extracted content and its JSON response, or save the same preview from the command line.
curl -fsSG --max-time 30 \
--data-urlencode 'url=https://anycrawler.com/crawler/page/fetch/' \
https://api.anycrawler.com/free/v1/crawl -o free.json
The preview in this check returned HTTP 200 and reported a target status of 200. Its Markdown contained the heading “Send a URL and get Markdown back.” The JSON supplied the requested URL and omitted the final target URL and credits used. In a separate Chrome read, the final target URL matched the requested one.
In a separate browser check, a missing AnyCrawler guide returned HTTP 404 and displayed “This guide does not exist.” The Python check uses that heading for a local test, pairing it with HTTP 200 to simulate the mismatch. Install the Python package markdown-it-py before running it. This example reads headings from the preview for a known documentation page. In a site adapter, first narrow the input to the primary document region.
import json
from pathlib import Path
from markdown_it import MarkdownIt
EXPECTED_TITLE = "Convert a URL into clean Markdown—without a browser."
EXPECTED_SECTION = "Send a URL and get Markdown back"
MISSING_TITLE = "This guide does not exist."
def classify(status, heading, sections):
if status in (404, 410):
return "target_unavailable"
if status != 200:
return "review_status"
if heading == EXPECTED_TITLE and EXPECTED_SECTION in sections:
return "expected_document"
if heading == MISSING_TITLE and EXPECTED_SECTION not in sections:
return "soft_404_candidate"
return "review_content"
preview = json.loads(Path("free.json").read_text(encoding="utf-8"))
if preview.get("ok") is not True:
raise RuntimeError("Preview request did not succeed")
results = preview.get("results") or {}
markdown = results.get("markdown") or ""
tokens = MarkdownIt("commonmark").parse(markdown)
headings = {"h1": [], "h2": []}
for index, token in enumerate(tokens):
if token.type == "heading_open" and token.tag in headings:
headings[token.tag].append(tokens[index + 1].content.strip())
main_heading = headings["h1"][0] if len(headings["h1"]) == 1 else ""
decision = classify(preview.get("status_code"), main_heading, headings["h2"])
print(decision)
assert classify(404, MISSING_TITLE, []) == "target_unavailable"
assert classify(200, MISSING_TITLE, []) == "soft_404_candidate"
assert classify(200, MISSING_TITLE, [EXPECTED_SECTION]) == "review_content"
assert classify(200, "", []) == "review_content"
assert classify(None, EXPECTED_TITLE, [EXPECTED_SECTION]) == "review_status"
The live preview produced expected_document. The local tests cover the hard status, the simulated soft 404, contradictory content, an empty response, and an unreported status. An unfamiliar heading stays in review. That matters when, for example, a documentation redesign updates the heading your adapter expects while leaving the resource available.
For a pipeline, record the requested URL, observed final URL if available, read time, status, and the heading or section that informed the decision. Those details let a reviewer check whether the response matched the expected entity. Search can help locate a replacement URL. Fetch reads public HTML that already contains the text, and Render can load a public JavaScript page. A screenshot preserves what a reviewer saw. Use an authorized interactive browser when the task requires a click or sign-in.
How much uncertainty can the index carry?
A wrong citation and a missed source have different costs. If a stale guide could send a user to a retired API, leave ambiguous captures out of retrieval until someone checks them. If missing documents would leave a research collection with important gaps, a review queue can retain the URL and evidence without indexing the questionable body. Before adding a rule for a new route or locale, decide which real pages can demonstrate that the rule recognizes both its missing template and its valid short pages.
Frequently asked questions
How can HTTP 200 accompany a missing page?
The server can successfully deliver HTML whose main content is an error message. For an extractor, the next check is whether that HTML contains the intended resource. Compare the page's primary heading and a known section or identifier with a trusted sample. If a known missing template appears in the main content and expected evidence is absent, keep the captured body out of retrieval pending review.
What is the difference between a hard 404 and a soft 404?
A hard 404 is the target's HTTP 404 response. A soft 404 can arrive as HTTP 200 and display a missing-page message. Store the actual status and the application decision in separate fields. This lets a reviewer see whether the server reported the missing resource or the extractor inferred it from the page. A single hard 404 does not establish that the URL is permanently gone.
Should I render every suspected soft 404?
Render when the expected content depends on JavaScript and the initial response looks like the app shell. Check the rendered result for the same document evidence you expected to see before capture. If the page already displays an explicit missing message from a known template, review that evidence before repeating the read. A render pass is most helpful when you can name the missing content it should reveal.
How do I avoid rejecting a legitimate empty page?
Check whether the page still identifies the correct resource. A collection can have a valid heading, the right scope or filters, and zero matching items. In that case, keep the empty result if it fulfills the pipeline's expected format. Use a representative empty example when testing the template so a rule intended for missing pages has to distinguish the two cases.
What should I log when a response looks like a soft 404?
Record the requested URL, the final URL when the client reports it, the actual target status, the capture time, and the classifier's reason. Keep a short excerpt of the heading or an allowed evidence snapshot so a reviewer can reproduce the decision. Leave unreported fields empty. Keeping the captured response linked to the verdict also makes it possible to revisit the rule when the site changes.






