All posts
Generative search5 min read

Why AI answer engines miss content on JavaScript-heavy pages, and how to check yours

A page can look complete in a browser and nearly empty to the crawler that decides whether it gets cited. Here is why that happens, what it costs in AI search, and how to measure the gap on your own pages.

DataForGAIO

Open a product page in Chrome and you see the full description, specs, pricing table, and FAQ. Request the same URL with a plain HTTP client and you may get a <div id="root"></div>, a bundle of script tags, and a page title. Both are the same page. Which one an AI answer engine sees depends on whether its crawler runs your JavaScript.

That's the most common reason we find for well-written pages being absent from AI answers.

Why the gap exists

A browser downloads the HTML, runs the scripts, fetches data from your API, and builds the page. That last step can take hundreds of milliseconds of CPU per page. Doing it for billions of URLs costs real money, so many crawlers either don't render at all or render only some pages, some of the time.

Google's Search crawler has rendered JavaScript for years, though rendering can happen later than the initial crawl. The AI operators' crawlers aren't uniform, and they don't all document their rendering behavior. When a crawler doesn't render, it reads the raw HTML your server sends. Anything that only appears after scripts run doesn't exist for it.

The safe assumption is simple: if it isn't in the server's HTML, an answer engine may not see it.

What usually goes missing

Body text is the obvious loss, but it's rarely the only one. From the checks we run, these are the patterns that matter most:

  • Main content rendered client-side. Single-page apps that fetch article or product data after load serve a near-empty shell.
  • Titles and meta descriptions set by JavaScript. Some frameworks set <title> in a client-side effect. The raw HTML carries a generic site title, or none.
  • Canonical URLs set or changed by JavaScript. A crawler that doesn't render may see a different canonical than Google does, or none.
  • Structured data injected by tag managers. JSON-LD added by a tag manager after load is invisible to a non-rendering crawler.
  • Internal links built by scripts. Navigation rendered client-side means the crawler can't discover the rest of the site from this page.
  • Content behind interactions. Tabs, accordions, and "read more" buttons that fetch their content on click don't exist in the raw HTML.

There's a separate problem that looks similar: the server treating bots differently. A firewall rule or bot-management product may answer GPTBot or PerplexityBot with a 403 or a challenge page while regular browsers get the content. From the outside it looks the same as "the AI doesn't know about our page".

How to check one page: Crawler view

Crawler view in the DataForGAIO dashboard shows a page the way AI answer engines read it. For one URL it:

  1. Fetches the raw HTML as a regular browser would request it, without running scripts.
  2. Renders the page in a real browser and captures the result.
  3. Requests the page with the documented user agents of AI and search crawlers such as GPTBot, OAI-SearchBot, ChatGPT-User, ClaudeBot, and PerplexityBot, and compares each response with the baseline.
  4. Checks robots.txt for every crawler on the list, including control tokens like Google-Extended that have no crawler of their own.

The comparison reports how much of the rendered text is already in the raw HTML (text_visible_pct). It also shows samples of text, headings, and links that only appear after JavaScript runs. Title, meta description, canonical, and JSON-LD each get one status: same, changed, js_only, removed_by_js, or missing.

Then it lists fixes in plain language, ranked by severity. Typical findings look like this:

FindingSeverityWhat it means
js_texthigh below 50% visibleMuch of the body text only exists after JavaScript runs
title_js_onlyhighThe <title> is empty or generic until scripts run
noindexhighThe raw HTML asks crawlers not to index the page
canonical_js_onlymediumThe canonical URL is only set client-side
jsonld_js_onlymediumStructured data is added after load
js_linksmedium at 10+ linksInternal links a non-rendering crawler can't follow

When a bot's response differs from the baseline (a different status, or a block or challenge page), Crawler view flags that bot by name. That's how you find the firewall rule nobody remembers adding.

A Crawler view run is billed like crawling: each fetch that returns real content costs the published page rate, and the browser render is billed at the browser page rate. Blocked or failed fetches and the robots.txt request cost nothing. The run shows its own line items.

How to check a whole site: Site audits

One page tells you whether the problem exists. Site audits tell you how far it reaches. An audit seeds from your robots.txt and sitemaps, then follows same-host links breadth-first, 100 pages by default and up to 1,000. Every page gets the same checks, and cross-page issues get grouped with evidence.

The audit findings that overlap with this topic:

  • not_real_content: the response isn't real page content. Usually an empty JavaScript shell, sometimes a block page.
  • thin_content: very little visible text.
  • ai_bots_blocked: robots.txt disallows AI crawlers for this path.
  • missing_title, missing_meta_description, missing_canonical, and missing_json_ld in the server HTML.
  • noindex, robots_disallowed, http_error, redirect_chain, and broken_internal_links.

Sort by issue and you'll usually find one template behind most of the problems: every product page, or every post in one section. Fix the template once and the whole group clears.

The same signal in the Crawl API

If you crawl pages through the API, the receipt flags the empty-shell case for you. When a fetch returns too little visible text to be content, content_check is empty_shell, the reasons say how much text there was, and the page costs $0:

{
  "status": "completed",
  "status_message": "Fetched, but the page has too little visible text to be content.",
  "cost": 0,
  "receipt": {
    "source_url": "https://shop.example.com/products/trail-runner-2",
    "http_status": 200,
    "content_check": "empty_shell",
    "content_check_reasons": ["visible_text_chars:84", "words:11"],
    "billed_usd": 0,
    "billed_pages": 0
  }
}

When you see empty_shell on your own pages, a non-rendering crawler sees what you just saw.

Fixes that work

  • Render on the server. Server-side rendering or static generation for content pages is the durable fix. Most current frameworks support it per route.
  • Put metadata in the initial HTML. Title, meta description, canonical, and JSON-LD belong in the server response, even if the body hydrates later.
  • Use real links. <a href> elements in the HTML, not click handlers on divs.
  • Ship tab and accordion content in the HTML. Hide it with CSS if you need to, rather than fetching it on click.
  • Check your bot rules. If a firewall or bot-management rule answers AI crawlers differently, make that a deliberate policy rather than a default.
  • Publish an llms.txt. It won't replace server-rendered content, but it gives answer engines a direct map to your canonical pages.

Then run the page through Crawler view again. When text_visible_pct is close to 100 and every bot gets the same response as a browser, the page is readable by every engine, whether it renders or not.

gaiojavascriptrenderingcrawler viewsite audits

Open a receipt for a page you choose.

Start free, crawl a URL, and check exactly what was billed and why.