Can Google see your React content? How to check with the URL Inspection tool
Search Console can show you the HTML Google got from your React page, and that's the quickest way to know whether your content made it. Run a live test in the URL Inspection tool, open View tested page, and search that HTML for a sentence your app only shows after it loads.
Google's own JavaScript SEO guide gives the same advice: use the Rich Results Test or the URL Inspection Tool and look at the rendered HTML. The screenshot looks reassuring, but the HTML is what you should trust. Here's how to read it, what to check when content is missing, and what this test doesn't tell you.
Run a live test on the page
Inspect the page's URL in the URL Inspection tool. The catch: the first result isn't your site as it is right now. Google's help page says this is not a live test, and the results come from the most recently indexed version of the page, not the live version on the web.
So click Test live URL on that result. That test fetches and examines the URL in real time, which is the one you want right after a deploy. It runs on URLs in your own Search Console property, so add the site there first if you haven't.
Read the HTML, not the screenshot
When the live test finishes, click View tested page. Google's help page lists what you get there: a screenshot of the rendered page, the raw HTML returned, the HTTP headers, JavaScript console output, and any page resources loaded.
Skip past the screenshot and open the HTML. Search it for text that only exists after your app has fetched its data:
- a product name, an article's opening line or a price from your API
- the page title and the main heading you set in the app
- a few internal links your router renders
- the canonical and robots meta tags, if your app sets them in the browser
If your sentence is there, that part is fine. If you only find an empty root element and script tags, the content you care about isn't in what Google returned, and that's the page to fix first.
Check the console output and the resources
When content is missing, check the details next. Google's help page says that to see a list of resources, page code and more information, you click View crawled page. Google's JavaScript fix guide says these tools show loaded resources, JavaScript console output and exceptions, rendered DOM, and more information.
- Look for an exception in the console output.
- Look for the script bundle and the API request that feed the page. If either didn't load, start there.
- Check the status code in the HTTP headers. Google's JavaScript SEO guide says pages that return a successful status code are sent to the rendering queue, no matter whether JavaScript is present on the page.
Compare the live test with the indexed version
A good live test shows the page as Google fetches it right now. It doesn't tell you the indexed copy has caught up. To see the HTTP request and response and the returned HTML, click View crawled page.
Don't expect the two to match the moment you ship a fix. Google's guide says Googlebot queues pages for both crawling and rendering, and the page may stay on this queue for a few seconds, but it can take longer than that. Google also uses the rendered HTML to index the page, so the rendered HTML is the version worth getting right.
When your content isn't in the HTML
Here are the things worth checking first on a React site, two of them straight from Google's JavaScript fix guide:
- Storage from an earlier visit. The guide says Local Storage and Session Storage data are cleared across page loads, so don't build the first view around a value your app saved before.
- Routes in the URL fragment. The guide recommends using the History API to load different content based on the URL in a SPA.
- Errors in the console. Fix the exception you found in the console output, then test again.
After the fix is deployed, run the live test again. Google's fix guide says that if you fixed the issue, a green check mark appears and no errors display. Then open View tested page once more and search for the same sentence.
Ask Google to recrawl the page
Once the live test shows your content, click Request indexing on the inspection result page for the URL. Two things to know from Google's help page: there is a daily limit to how many index requests you can submit, and submitting a request does not guarantee that the page will appear in the Google Index.
In short, use requests on the pages that matter most, like your key landing and product pages, and let the rest get picked up through normal crawling.
Google isn't the only crawler reading your site
Passing this test tells you about Google, not about the other bots that read your pages. Google's JavaScript SEO guide says server-side or pre-rendering is still a great idea because it makes your website faster for users and crawlers, and not all bots can run JavaScript.
If you want bots that can't run JavaScript to get finished HTML, pre-rendering is one way to do it. RenderSwap, which we make, is a hosted prerender service. It opens your own public pages in a browser and returns the finished HTML to search and AI crawlers that do not run scripts. When a render fails, the crawler gets your origin's own page. The Free plan includes 1 verified domain and 500 fresh renders or 1 browser hour a month, whichever comes first, and you sign up without a card or an email.
Sources
- Search Console URL Inspection tool help
- Google's JavaScript SEO basics guide
- Google's guide to fixing Search-related JavaScript problems
Questions
Is the first URL Inspection result what Google sees right now?
No. Google's help page says that result is not a live test: it comes from the most recently indexed version of the page, not the live version on the web. Click Test live URL to fetch and examine the URL in real time.
Can I check a page that isn't in my Search Console property?
The live test in the URL Inspection tool runs on URLs in your own property. Google's JavaScript SEO guide also names the Rich Results Test as a way to look at the rendered HTML.
Does requesting indexing get the page indexed?
Not for certain. Google's help page says there is a daily limit to how many index requests you can submit, and submitting a request does not guarantee that the page will appear in the Google Index.
If Google renders my page fine, do I still need prerendering?
That depends on which other crawlers you care about. Google's JavaScript SEO guide says server-side or pre-rendering is still a great idea, because it makes your website faster for users and crawlers and not all bots can run JavaScript.
Related
- How to test that your prerender setup works: fetch the page as a crawler and read the HTML
- How to make prerender-node serve AI crawlers: check the list, add the missing bots, test it
- Prerender service down or timing out? Make prerender-node fall back to your own page
- How to point prerender-node at a different prerender service: the service URL and the token