Sub topic 5
Finding broken links and redirect problems
This chapter covers how to find broken links, server errors and redirect problems in a Screaming Frog crawl, and how to trace each one to the pages that need editing. It assumes you can run a crawl and read the Internal tab (earlier chapters), know the HTTP status code families, and have permission to crawl the site.
Why status codes matter in a crawl
Every URL the SEO Spider requests returns a status code. Three groups need your attention:
- 3xx redirects send visitors and crawlers to another URL. They are normal, but internal links should not depend on them.
- 4xx client errors mean the URL does not work. A 404 on a linked page wastes a visit and a crawl request.
- 5xx server errors mean the server failed. They may be temporary, or they may be a bug that only appears for certain URLs.
A missing response is a separate case. The spider reports it with status code 0 and a reason such as a DNS failure or a connection timeout.
Where to look in the interface
Open the Response Codes tab in the main window. The filter drop-down lists these groups:
| Filter | What it contains | Typical action |
|---|---|---|
| Blocked by Robots.txt | URLs disallowed by robots.txt | Confirm the block is intended |
| Blocked Resource | Page resources (CSS, JS) that were blocked | Check rendering is not affected |
| No Response | Requests that got no HTTP reply | Re-test, then check DNS and server |
| Success (2xx) | Pages that returned 200 | Nothing to fix |
| Redirection (3xx) | URLs that redirect | Update internal links to the final URL |
| Redirection (JavaScript) | Redirects done by scripts | Replace with server-side redirects |
| Redirection (Meta Refresh) | Redirects done by a meta tag | Replace with server-side redirects |
| Client Error (4xx) | Broken URLs | Fix links or restore or redirect the page |
| Server Error (5xx) | Failed requests | Investigate with developers |
The Internal tab has the same data in a "Status Code" column. The Response Codes tab is better for triage because it groups URLs by problem. The Overview panel on the right shows a count for each filter, so you can see the size of each problem before you open it.
Finding the pages that contain a broken link
The broken URL is not the thing you edit. You edit the page that links to it. Select a URL in the Client Error (4xx) filter, then open the Inlinks tab in the lower pane. It lists every page that links to that URL, along with the anchor text and the link position (for example navigation, content or footer).
For many broken URLs at once, use Bulk Export > Response Codes > Client Error (4xx) Inlinks. The export has one row per link, with source page, destination and anchor. Hand it to whoever edits the content.
Check the link position column before deciding how much work a problem is. A broken link in the footer appears on every page, so one template edit fixes thousands of rows. A broken link in body copy needs a manual edit on each page.
Redirects: what to fix and what to leave
A single 301 from an old URL to a new one is valid. Problems start when internal links still point at the old URL. Each visit then costs an extra request, and search engines keep revisiting the old address.
Select a URL in the Redirection (3xx) filter. Two columns matter: Redirect URI (where it points) and Status Code (301, 302, 307, 308). Then use the Inlinks tab to find the pages linking to the redirecting URL. The fix is to change those links to the Redirect URI.
Watch the code type:
- 301 and 308 are permanent. Use them for moved content.
- 302 and 307 are temporary. If you see one on a page that moved for good, ask for it to be changed to a permanent redirect.
- Meta refresh and JavaScript redirects are slower and less reliable than server redirects. Treat them as findings.
Redirect chains and loops
A chain is A redirects to B, which redirects to C. A loop is A redirects to B, which redirects back to A. Browsers give up on loops and show an error.
The Response Codes tab shows only the first hop. To see the whole path, use Reports > Redirects > Redirect Chains. The report gives the number of redirects in each chain, whether it loops, and each address along the way. Fix a chain by pointing the first URL straight at the last one, and update the internal links too.
If you crawl from a list of URLs (List mode) rather than a whole site, the spider does not follow redirects unless you turn on Configuration > Spider > Advanced > Always Follow Redirects. Without it, the chain report will be empty or incomplete. In normal Spider mode the crawl follows redirects found on linked pages.
Processing the results outside the interface
For repeated checks, export the data and filter it with a script. The following command crawls a site headlessly and exports the Internal tab. Run it only against a site you own or have permission to crawl.
screamingfrogseospider --crawl https://www.example.com \
--headless \
--save-crawl \
--output-folder /tmp/sf-crawl \
--timestamped-output \
--export-tabs "Internal:All"The script below reads the exported file and prints every URL with a 4xx or 5xx status. The utf-8-sig encoding strips the byte-order mark that spreadsheet-friendly CSV exports often start with. Without it, the first column name can read incorrectly.
import csv
with open("/tmp/sf-crawl/internal_all.csv", newline="", encoding="utf-8-sig") as f:
for row in csv.DictReader(f):
if row["Status Code"].startswith(("4", "5")):
print(row["Status Code"], row["Address"])Note that --timestamped-output places the files in a dated subfolder inside /tmp/sf-crawl. Adjust the path in the script to match the folder the crawl created.
Common errors and edge cases
- Status code 0 is not a 404. It means the spider received no HTTP response. Check the Status column text for the cause. Retry the URL in a browser before you report it.
- Intermittent 5xx errors. A fast crawl can overload a small server, which then returns 503 or 429 responses. Lower the speed under Configuration > Speed and re-crawl those URLs before you call them site bugs.
- Soft 404s. A page that says "not found" but returns 200 will not appear in the Client Error filter. Find these with a Custom Search for the error text, or by checking pages with very short content.
- Blocked by robots.txt. The spider does not request these URLs, so their real status is unknown. Do not read "blocked" as "working".
- Stale redirect targets. A redirect that ends in a 404 is a broken link in disguise. The chain report shows the final status, so check the last row.
- Links to external sites. External broken links appear under the External tab. They are worth fixing but are lower priority than broken internal links, because you control the internal ones completely.
- Crawl depth and limits. If a crawl hit a configured limit, some broken URLs were never requested. Confirm the Overview totals look complete before you treat the list as final.
A repeatable workflow
- Crawl the site and open the Response Codes tab.
- Review the counts in the Overview panel for 4xx, 5xx and No Response.
- For each 4xx and 5xx URL, check Inlinks and note the link positions.
- Export Client Error (4xx) Inlinks for the editors.
- Open Redirection (3xx), then run the Redirect Chains report and note chains and loops.
- Fix the links, then re-crawl to confirm the counts drop. A later chapter shows how to compare the two crawls.
Exercise
A crawl shows 400 URLs in the Client Error (4xx) filter. Most come from one broken image link in the site footer. Which export gives you the pages to edit, what do you expect to find, and what is the efficient fix?
Show answer
Use Bulk Export > Response Codes > Client Error (4xx) Inlinks, which lists one row per link with the source page, destination and link position. You should see the footer position repeated on hundreds of source pages. The efficient fix is one edit to the footer template, not editing each page. Re-crawl afterwards to confirm the 4xx count falls.
Exercise
The Redirect Chains report shows /old to /interim to /new, and 50 internal links point at /old. What should you change?
Show answer
Make /old redirect directly to /new so the chain has one hop. Update the 50 internal links to point at /new as well, so visitors and crawlers do not use a redirect at all. Re-crawl to check that the chain is gone.