Skip to content
Searchpedia SEO field notes Callum Bennett Callum

Site ops

SEO Cloaking

I've seen too many sites penalised because they didn't realise their mobile version was serving different content to Googlebot than to users.

Beginner3 min readUpdated 2026-07-27Notes by Callum Bennett

Start here

  • Use Search Console's URL Inspection tool to compare what Google sees with the live page.
  • Review your server configuration for any User-Agent or IP-based logic that serves different content.
  • Check that your mobile site or dynamic serving does not truncate or alter main content.
  • If you use localisation via IP redirects, verify that Googlebot sees the same content as users.
  • Regularly audit your site using a crawler that simulates Googlebot to detect mismatches.

Plain-English take

Think of it like this: you have a shop window. You show the health inspector a selection of premium cheese, but sell standard cheddar to actual customers. That is cloaking. On the web, cloaking means serving different content to Googlebot than to human visitors. The goal is usually to rank for keywords that the visible page does not actually contain. Google treats this as deceptive and explicitly bans it under its spam policies. A typical example: an e-commerce site delivers 1,200 words of product description and customer reviews to Googlebot, but the user sees a 50-word summary and an image. That discrepancy is a red flag. Cloaking can involve text, links, metadata or entire pages. It is not limited to hidden text; any intentional mismatch counts. The key test: if you take a screenshot of what Googlebot sees and compare it with what a user sees, they should be equivalent. If they are not, you risk manual action or algorithmic ranking loss. Google's Search Essentials state that cloaking violates guidelines and can result in deindexing. Always serve the same core content to everyone, even if the layout adjusts for devices or languages. Legitimate personalisation – such as showing localised pricing – is fine as long as the main content remains the same. Cloaking is the line where that equivalence breaks.

When it actually matters

Cloaking is not just a black-hat tactic from the early 2000s. It still happens accidentally, which is why it matters today. If your site uses dynamic serving – different HTML for different devices – you might be cloaking without realising it. For example, many WordPress themes serve a mobile version that truncates paragraphs to improve load times. If that version removes the main content, Googlebot sees one thing and users another. That is a violation. Similarly, if you use IP-based redirects to show localised content, but serve different text to Googlebot's IP range, you must ensure equivalence. E-commerce sites that show personalised pricing based on User-Agent risk penalties if Googlebot sees a different price. Another common scenario: sites that use JavaScript to load content, then serve a static fallback to Googlebot that differs from the dynamic content users see. This is not always cloaking – it depends on intent and equivalence. Use the URL Inspection tool in Search Console to check what Googlebot rendered. If it looks different from the live page, investigate. Also review your server configuration: any .htaccess or nginx rule that checks User-Agent should be scrutinised. Legitimate uses, like serving lighter assets to slow connections, are fine if the content is identical. The difference between optimisation and cloaking is whether the core message changes. Check your [mobile site setup](/mobile-seo/) and [technical SEO configuration](/technical-seo/) for these issues. If you serve different content to mobile, that can create [duplicate content](/duplicate-content/) problems. Proper use of [canonical tags](/canonical-tag/) can help but does not excuse cloaking. For sites that rely on JavaScript, see [JavaScript SEO](/javascript-seo/) for guidance on equivalence. Also review your [robots.txt](/robots-txt/) for any User-Agent disallow rules that could cause mismatches.

What I got wrong

I used to think cloaking only meant hidden text – white text on white background, keyword stuffing in invisible divs. That is one form, but the definition is broader. Any deliberate difference in content between what Google sees and what a user sees is cloaking. I also confused cloaking with responsive design. Responsive design changes layout, not content. If your mobile site removes a paragraph that is present on desktop, that is cloaking, not responsiveness. Another mistake: I once thought serving different content to mobile users was acceptable as long as it was 'better' for them. But Google requires equivalence. The page must contain the same main content, even if formatted differently. I also overlooked IP-based serving. I implemented a redirect for users in certain countries using IP detection, but I served different text to Googlebot – that was a clear violation. The hardest lesson: detecting cloaking in your own site is difficult because you assume everything is fine. You need to actively compare bot and user views. Use a tool like curl with a Googlebot User-Agent to fetch your page and compare it to what a browser renders. If the HTML differs in meaningful ways, you have a problem. Now I always audit my sites for these mismatches as part of a routine technical SEO check.

Next step

Quick answers

Is cloaking always intentional?

Not always. Accidental cloaking happens when server configurations or CMS templates serve different content to crawlers without the site owner's knowledge. However, Google treats both intentional and unintentional cloaking as violations. The best practice is to regularly audit your site to ensure equivalence.

Can cloaking be fixed without changing the user experience?

Yes, by ensuring that the content Googlebot sees is equivalent to what users see. You may need to adjust your server-side logic or templates to serve the same main content to all visitors. Avoid hiding content solely for SEO purposes; instead, improve the visible page.

How do I check if my site is accidentally cloaking?

Use Google Search Console's URL Inspection tool to view the rendered version Google sees. Compare it with the live page in your browser. Also test with a tool like 'curl -A Googlebot' to fetch the raw HTML. Look for differences in text, links, or metadata.

Sources

Primary documentation is linked directly. Anything commercial is marked nofollow.

Notes from Callum Bennett.