Technical SEO

What does Googlebot see of service workers?

Googlebot rejects service workers. Here is how to check whether your pages arrive complete without them.

Returning visitorsw.js activeGooglebotRejectedCacheServer
Michael WeberFirst published: December 11, 2020Last updated: October 15, 20268 min read
Experiment from 2020

The test dates from December 2020. The section What has changed since then? describes where Google stands today.

In short
  • Googlebot does not run service workers. According to Google, the renderer works without stored state. For Googlebot, every request is a first visit.
  • In our live test in Search Console, registration failed with “Registration failed: Rejected”.
  • All content, links and SEO elements must therefore arrive complete in the HTML without a service worker. The service worker may only speed things up.

Our test in Search Console

For a progressive web app, we wanted to know what Googlebot does with the service worker. So we built a test page that registers a file sw.js with the scope “/” on load and prints the result on the page. We tested this page live with the URL Inspection tool in Search Console.

CheckResult in the live test
Service worker registrationFailed
MessageRegistration failed: Rejected
Tests passed0 of 1

The message gives no reason. Still, this is not a bug, because Googlebot behaves the way Google built the renderer.

Why doesn't Googlebot run service workers?

Since May 2019, Googlebot has rendered with a current version of Chromium. At the time, Google spoke of over 1,000 new features compared with the old Chrome 41, including ES6, IntersectionObserver and Web Components. Service workers were not on the list.

The reason lies in how the Web Rendering Service (WRS) is built. According to Google's documentation, it keeps no state between two page loads. Cookies, local storage and session storage are cleared, and Googlebot declines permission requests. A service worker only helps on the second visit, because it stores files for later. For Googlebot, every request is a first visit, and users coming from search have often never been on the page before.

FeatureIn a returning visitor's browserWhen Googlebot renders
Service workerInstalled, serves from the cacheRegistration rejected
HTTP cookiesKeptCleared between page loads
Local and session storageKeptCleared between page loads
Permissions (location, camera, notifications)Active after consentDeclined

The feature detection trap

The check 'serviceWorker' in navigator still returns true in the renderer, because Chromium knows the interface. Only the call to register() fails. If you only check for support and then make content depend on the service worker, you show Googlebot an empty or half-empty page. sw.js may still show up in server logs as a request by Googlebot. The file is not executed.

Typical failure patterns

The same patterns keep coming up in forums and in our own analyses.

  • Subpages only via the service worker. The app expects the user to load the homepage first and the service worker to deliver all further pages afterwards. Googlebot requests subpages directly and gets an empty shell or an error. In extreme cases, only the homepage ends up in the index.
  • SEO elements change on the second visit. The service worker swaps the title, description or structured data, for example for A/B tests. Googlebot sees a different version from returning visitors. This can be treated as cloaking.
  • Cache-first for changing content. Returning visitors see old prices or text for weeks, while Googlebot sees the current state. For many users, the search result then does not match the page.
  • Service worker from the framework default. Starter templates and PWA plugins often ship a service worker with aggressive caching, without the team knowing.

How to use service workers safely for SEO

  1. Progressive enhancement. Every page works fully without a service worker. It only speeds up repeat visits.
  2. Catch errors. If registration fails, the page keeps running without a message.
  3. Deliver content from the server. Server-side rendering or static generation for the first request, then hydration in the browser. Next.js, Nuxt, SvelteKit, Angular SSR and Gatsby support this.
  4. Network-first for changing content. The service worker asks the server first and only falls back on the cache if that fails.
  5. Set the scope deliberately. An sw.js under /blog/ only controls URLs under /blog/. For the whole website, it belongs in the root directory.
  6. Never change SEO elements in the service worker. Title, description, canonical, meta robots, hreflang, structured data and Open Graph tags are the same for all visitors.

This is what a registration looks like that does not disturb Googlebot.

if ('serviceWorker' in navigator) { navigator.serviceWorker.register('/sw.js') .then(reg => console.log('SW active', reg.scope)) .catch(err => { // Googlebot ends up here. The page keeps running normally, // without an error message and without missing content. console.log('SW not registered', err); }); }

This is what a simple network-first strategy looks like in the service worker.

// sw.js · Network-first: server first, cache only if it fails self.addEventListener('fetch', event => { event.respondWith( fetch(event.request).catch(() => caches.match(event.request)) ); });

Edge workers as an alternative

If responses need to be adjusted for all visitors, for example for redirects or tests with metadata, an edge worker is the right place. Cloudflare Workers, Lambda@Edge, Fastly Compute or Netlify Edge Functions run on the server before the response reaches the browser. Googlebot gets the same response as every other visitor. If the website needs neither offline mode nor background sync, doing without a service worker is often the simplest solution.

How to check your pages

For a first look, use our Service Worker Test. It shows whether a page registers a service worker, what the page uses it for and what a crawler gets on the first visit without it. Then continue checking by hand.

  1. Open Chrome DevTools, the “Application” tab, the “Service Workers” section.
  2. Enable “Bypass for network”. The browser then loads pages as if there were no service worker.
  3. Under “Storage”, delete all stored data with “Clear site data”.
  4. Open a subpage directly and reload it. Text, images, navigation, crawlable links and the title and meta tags in the source code must be there.
  5. In Search Console, start URL Inspection and choose “Test live URL”. Compare the screenshot, rendered HTML and console messages with the source code.

The message “Registration failed: Rejected” in the console is to be expected. All that matters is whether everything is there without a service worker. If content is missing, there is an architecture problem that a setting cannot fix.

searchVIU Service Worker Test

The test fetches a URL like a new visitor and renders it without an active service worker. This is how Googlebot gets every page too. The test then looks for the registration in the source code, in the rendered HTML and in up to 15 of the page's scripts. It reads the service worker script without running it.

  • Registration with script address, scope and the Service-Worker-Allowed header. If the scope is above the script's folder or the script is served with the wrong content type, the test reports an error.
  • Usage: offline page, precache, caching strategy per resource type, push messages, background sync, navigation preload and the detected library, such as Workbox with its version.
  • Cache: the offline page and up to 10 precache files with their status code. If one file is missing, the service worker's installation aborts.
  • Signals on the first visit: status code, title, canonical, meta robots, H1, words and links, plus a comparison of the selected user agent with Chrome.

The test does not yet run a second visit in which the service worker already controls the page. It derives what returning visitors see differently from the script.

The previous tool on searchviu.com was a self-test. It registered a service worker in whichever browser opened the page and checked cache, messaging and background sync there. Combined with the URL Inspection tool in Search Console, this showed how Googlebot reacts. The new test checks any URL from the outside. For Googlebot's own view, the URL Inspection tool in Search Console remains the direct route.

What has changed since then?

Google retired the Mobile-Friendly Test, which in 2020 offered a second look at Google's rendering, at the end of 2023. For testing, the URL Inspection tool in Search Console remains. Google's documentation still describes the renderer as stateless and based on a current version of Chromium (as of March 2026). The test page still shows the same result in the live test.

Common mistakes

  • Feature detection is taken as proof that the service worker is running.
  • Content or internal links only get onto the page via the service worker.
  • If registration fails, the page shows an error message or stays empty.
  • Cache-first for pages with prices, availability or news.
  • The framework's default service worker stays active without being checked.

FAQ

Does Googlebot support service workers?

No. In the Search Console live test, registration is rejected with “Rejected”. Googlebot renders every page without stored state.

Does a service worker hurt my SEO?

Not as long as the page works fully without it. Problems arise when content, links or SEO elements depend on the service worker.

What does “Registration failed: Rejected” mean in Search Console?

Googlebot has rejected the service worker registration. This is intended. Check whether the screenshot and the rendered HTML still show all content.

Is a PWA bad for SEO?

No. A PWA with server-delivered content is a normal website for Google. Only a PWA that loads content via the service worker is a problem.

Which caching strategy is safe for SEO?

Network-first for content that changes. Cache-first suits files that rarely change, such as fonts or versioned CSS and JS files.

Does Googlebot see the sw.js file?

Googlebot can fetch it, and it then shows up in the server logs. It is not executed during rendering.

searchVIU renders every page in real Google Chrome and stores the raw and the rendered HTML. The comparison for each URL shows where content, links or titles only appear or disappear through JavaScript. Find out more on the SEO Crawler page.

Request a demo

Sources

Retrieved on October 15, 2026. If something is out of date or missing, let us know.

  1. Google Search Central Blog, The new evergreen Googlebot: https://developers.google.com/search/blog/2019/05/the-new-evergreen-googlebot · May 7, 2019
  2. Google, Understand the JavaScript SEO basics: https://developers.google.com/search/docs/crawling-indexing/javascript/javascript-seo-basics · As of Mar 4, 2026
  3. Google, Fix Search-related JavaScript problems: https://developers.google.com/search/docs/crawling-indexing/javascript/fix-search-javascript · As of Dec 18, 2025
  4. MDN, Service Worker API: https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API
  5. Search Engine Land, Google drops Mobile-Friendly Test: https://searchengineland.com/google-officially-drops-mobile-usability-report-mobile-friendly-test-tool-and-mobile-friendly-test-api-435377 · December 2023