A JavaScript SEO Audit for Rendering and Crawl Problems

clock Nov 11,2026
pen By SEO ANALYSER
JavaScript SEO audit concept

Technical SEO guide

Scripts that build a page change what Google receives and when. Here are the rendering and crawl checks that separate a harmless difference from one that costs indexing.

Short answer

Audit each template twice, once as raw HTML and once as rendered output, and treat every difference as a risk to be explained

Google processes JavaScript sites in three phases, crawling, rendering and indexing, and rendering can happen some time after the initial fetch. An audit of a JavaScript-heavy site therefore compares what the server sends with what exists after scripts run, checks that links, directives, status codes and resources survive rendering, and confirms the result in the URL Inspection tool. Where the two versions disagree, the audit needs a documented reason, because Google's own guidance shows several ways in which the disagreement can cost indexing.

The checks below follow Google's documentation and are ordered by template and by dependency, so that a fault that affects every page is found before a fault that affects one. The raw version also matters beyond Google, because the AI crawlers examined in one 2024 analysis did not execute scripts.

Why it differs

What changes when content depends on rendering

On a server-rendered site the first response already contains the content, the links and the directives, so a crawl of the raw HTML is a fair picture of what Google receives. On a site that builds pages in the browser, the first response may be a shell, and everything of interest appears only after scripts run. Googlebot queues pages for both crawling and rendering, pages returning a 200 status are generally queued for rendering, and error pages may skip it. The consequence for an audit is that two crawls are needed on the same URLs, one without script execution and one with it, and the comparison between them is the core finding.

The comparison should be made per template and not per URL. A product page, a category page, an article and a search results page each have their own rendering path, so a sample of each reveals the fault patterns that scale across thousands of URLs. Differences worth recording are missing body content, missing or changed links, changed titles, canonical tags and robots directives, and structured data that appears only after rendering.

HTML source versus rendered page: what the server sends compared with what exists after scripts run

Checks

The rendering and crawl checks that matter

CheckHow to verifyFailure documented by Google
Content in rendered outputPage HTML in URL InspectionExpected content missing after scripts run
Crawlable linksAnchor elements with href in rendered HTMLOnly standard anchors with an href are followed
RoutingURLs that change through the History APIFragment-based URLs are unreliable for Googlebot
Status codesResponse for missing and removed pagesSoft 404s in single-page applications
DirectivesRobots meta and canonical in raw and rendered HTMLnoindex in the original HTML may stop rendering
Blocked resourcesrobots.txt rules for script and data filesDisallowed files are not fetched
State and permissionsBehaviour with no stored state or permission promptsStorage is cleared between loads and features needing permission, such as a camera, are unavailable
Essential rendering and crawl checks for a JavaScript-heavy site

Method

How to run the audit in six steps

  1. 01

    Inventory the templates and their rendering mode

    List each page type and how its content reaches the browser, such as complete server output, a shell filled by scripts, or a mixture. This decides where the risk concentrates.

  2. 02

    Compare raw and rendered output per template

    Crawl a sample of each template without script execution, then with it, and record every difference in content, links, titles and directives.

  3. 03

    Check links and routing

    Confirm that navigation uses anchor elements with an href attribute and that client-side routing uses the History API and not fragments.

  4. 04

    Test status codes for missing pages

    Request URLs that should not exist and check what the server and the rendered page report. A soft 404 shows a not-found message with a 200 status.

  5. 05

    Check directives and blocked resources

    Compare the robots meta and canonical in both versions, and confirm that the rules described in the guide to robots.txt do not block script or data files that rendering needs.

  6. 06

    Confirm in URL Inspection and retest after fixes

    Inspect representative URLs, read the console output and loaded resources, and run a live test after each fix to confirm the change.

Directives

Conflicts between the original HTML and the rendered page

Directives are where rendering faults do the most damage, because they change indexing decisions. Google may skip rendering when it sees a noindex tag in the original code, so a template that ships noindex in the server response and removes it with JavaScript may not behave as intended. The reverse pattern, a clean original response with a noindex injected later, is visible only in the rendered version, which is why both versions need checking.

Canonical tags follow a similar rule. Google can read a canonical tag injected by JavaScript, but HTML is preferred, the injected value must match any canonical already in the original HTML, and there should be only one canonical tag on the page. Two different canonicals, one before and one after rendering, create an inconsistency that the audit should list as a defect even if Google resolves it in a particular case.

Resources need the same scrutiny. If robots.txt disallows a URL, Googlebot will not fetch it, so JavaScript in a blocked file will not run for Search. A rule that blocks a script directory can be the reason a template renders blank.

Routing

Status codes and URLs in single-page applications

Client-side routing often makes accurate HTTP status codes impractical, because the server returns the same shell for every path. Google's guidance for missing content is to use a JavaScript redirect to a URL that returns a 404 status, or to add a noindex robots meta tag to the error view with JavaScript. Without either, every invalid path can look like a valid page returning a 200 status, and soft 404 pages can result.

URL structure matters for the same reason. The History API is the recommended routing approach, and Googlebot does not rely on fragments such as a hash followed by a path. A site whose product pages are reachable only through fragment URLs depends on URLs that Googlebot cannot reliably resolve.

Document the difference, not only the defect

For each template, the audit record should show what the raw response contained, what the rendered page contained and what Google's tool reported, so that a fix can be verified against the same three observations.

Environment

Features that depend on the browser environment

Google's troubleshooting guidance lists several assumptions that fail for Googlebot. It cannot provide features that need user permission, such as a camera, so content must be reachable without them. Local storage, session storage and cookies are cleared between page loads, so content should not depend on stored state. It does not support WebSockets or WebRTC, so an HTTP fallback is needed, and unsupported APIs such as WebGL should be feature-detected with a fallback or server-side rendering. Googlebot also caches aggressively and may ignore caching headers, which is why content fingerprinting in file names is recommended.

One further rule concerns access control. Google's guidance is that a paywall should provide the full content only once the subscription status is confirmed.

AI crawlers

Raw HTML is what most AI crawlers see

Googlebot is not the only consumer of a page. A December 2024 analysis by Vercel of crawler traffic on its network, checked against two validation sites, found that none of the major AI crawlers it examined rendered JavaScript, including those used by ChatGPT, Claude and Perplexity. The crawlers behind ChatGPT and Claude fetched JavaScript files but did not execute them, while Gemini used Googlebot's infrastructure and AppleBot rendered pages. Content that exists only after rendering may therefore be indexed by Google and still be missing from what those platforms can read.

The finding has limits. It rests mainly on one site's traffic plus the two validation sites, and it dates from December 2024, so crawler behaviour may have changed since; it is best treated as the result of one analysis and not as a permanent rule. Its authors also note that content in the initial HTML may still be used. For an audit, the practical consequence is that the raw version of each template is a direct check of what those platforms can draw on, and whether such pages are then cited is a measurement question covered in the guide to measuring AI visibility.

Verification

What the testing tools can and cannot prove

The URL Inspection tool separates an indexed result, which shows the most recently indexed version, from a live test, which fetches the URL in real time. Both views provide the page HTML, HTTP headers, console output and loaded resources, and a screenshot is available only in a live test. Google states that the live test only confirms whether Google-InspectionTool can access the page for indexing, that it does not check sitemaps or referring pages, and that it cannot predict whether the tested version will be considered canonical. Daily quotas apply to inspections, live tests and indexing requests, so sampling by template is the practical approach.

At site level, the Crawl Stats report adds a second view, with its own limits: client-side redirects are not counted, server-side redirects are counted hop by hop, and totals can differ from server logs. A redirect implemented in JavaScript will therefore be invisible in that report, and its effect must be confirmed by inspecting the destination URLs directly. The effect of heavy scripts on loading is a separate topic, covered in the guide to site speed optimisation.

A live test is a check, not a prediction

A passing test shows that a fetch and render worked at that moment. It does not guarantee indexing, so the audit should also confirm that the indexed version matches the intended content.

SEO Analyser

Check directives and frameworks across the whole site

SEO Analyser's Web Audit checks canonical tags and noindex directives, including those set in the X-Robots-Tag HTTP header, and detects the frameworks a site runs on, which helps with the template inventory and the directive checks above. It does not replace URL Inspection for confirming how Google renders a page. 7-day free trial, no credit card required.

Start free trial

Frequently asked questions

JavaScript SEO audit FAQs

What is the difference between raw HTML and rendered HTML in an audit?

Raw HTML is the response the server returns before scripts run, and rendered HTML is the DOM after Google has executed JavaScript. Google describes crawling, rendering and indexing as separate phases, and rendering can happen some time after the initial fetch, so content that exists only in the rendered version depends on that second step.

Which tool shows what Google rendered for a URL?

The URL Inspection tool in Search Console. An indexed result shows the HTML, HTTP headers, JavaScript console output and loaded resources for the most recently indexed version, and a live test fetches the URL in real time. A screenshot of the rendered page is available only in a live test.

Can a live test predict whether a page will be indexed?

No. Google states that the live test only confirms whether Google-InspectionTool can access the page for indexing, that it cannot predict whether the tested version will be considered canonical, and that no test can guarantee inclusion in the index.

How should a single-page application handle pages that do not exist?

Client-side routing often makes accurate HTTP status codes impractical. Google's guidance is to use a JavaScript redirect to a URL that returns a 404 status, or to add a noindex robots meta tag to the error view with JavaScript, so that missing pages are not treated as soft 404s.

Are links added by JavaScript crawlable?

Google can follow standard anchor elements with an href attribute, and links injected with JavaScript are acceptable if they meet that requirement. Navigation built from other elements, or from fragment-based URLs, is not reliable for Googlebot.

Do AI crawlers execute JavaScript?

In a December 2024 analysis by Vercel, none of the major AI crawlers examined rendered JavaScript, while Gemini used Googlebot's infrastructure and AppleBot did render pages. Behaviour may have changed since, so the result is a dated observation and not a rule.

Summary

Compare what the server sends with what renders, per template. Check links, routing, status codes, directives and blocked resources, confirm in URL Inspection and retest after each fix.

References

Sources and further reading