🛠️ OTTO Headings & HTML Entities Cloudflare Worker Fix

Camilo Aponte

Camilo Aponte

Last updated on Sep 30, 2026

🔍 Overview

If your site uses OTTO SEO with a Cloudflare Worker to inject optimizations, you may have noticed that heading changes (H1, H2, etc.) appear correctly in your browser but are not visible in Google Search Console's (GSC) Live Test or are inconsistent in View Page Source. This issue specifically affects headings that contain HTML entities — for example, an ampersand rendered as &, a registered trademark symbol (®), or similar encoded characters.

⚙️ What Causes This Issue

OTTO delivers heading optimizations by injecting a script via Cloudflare Worker that matches existing heading text on the page and replaces it with the optimized version. When a heading contains an HTML entity (such as & stored as & in the page source), the Worker script encounters a mismatch:

  • The page source contains the encoded version of the character (e.g., &).
  • The OTTO script tries to match the decoded or differently encoded version.
  • Because the text does not match exactly, the Worker skips the heading replacement entirely.
  • In some cases, the script re-encodes the entity a second time, causing double-encoding (e.g., &), which can break heading styling and display incorrect text.

Your browser is forgiving — it decodes and renders HTML entities automatically, so the heading looks correct to a human visitor. However, Google's crawlers and the GSC Live Test read the raw page source, where the mismatch or double-encoded entity is visible, meaning Googlebot may not see your optimized heading at all.

✅ What Has Been Fixed

Our engineering team has identified and resolved this bug. The fix ensures that:

  • The Cloudflare Worker script correctly normalises HTML entities before attempting to match heading text, so encoded characters no longer cause a mismatch.
  • Double-encoding is prevented — entities are decoded once, matched accurately, and re-encoded correctly in the final output.
  • Heading optimizations are now applied consistently in both the browser and the raw page source, making them visible to Google's crawlers and the GSC Live Test.

This fix is being rolled out as part of an active release. If your site was affected, the corrected behavior will apply automatically once the update reaches your site's Worker configuration — no action is required on your part.

📊 How to Confirm Optimizations Are Working

After the fix has been applied to your site, follow these steps to verify that OTTO heading optimizations are now visible in both the browser and GSC:

  1. Go to Google Search Console and open the URL Inspection tool.
  2. Enter the URL of a page where OTTO has applied a heading optimization.
  3. Click Test Live URL and wait for the crawl to complete.
  4. Open the HTML tab within the live test results and search for your optimized heading text.
  5. Confirm the heading appears with the correct, optimized content and no double-encoded characters.

You can also use your browser's View Page Source (right-click → View Page Source, not Inspect Element) to check the raw HTML. The optimized heading should be visible in the source with correctly encoded entities.

💡 Additional Checks in OTTO SEO

To review the heading optimizations OTTO has deployed on your site:

  1. In Search Atlas, click OTTO SEO in the left sidebar.
  2. Select your connected site and open the deployed optimizations view.
  3. Filter by Headings to see which H1 and H2 optimizations are active.
  4. Cross-reference these with the GSC Live Test results to confirm successful deployment.

If you see a heading optimization listed as deployed in OTTO but it is still not appearing correctly in GSC after the fix rollout, note the specific URL and heading text (including any special characters) for our support team.

🚀 Preventing Future Issues

While this bug has been fixed, keep the following best practices in mind when working with OTTO heading optimizations on pages that use special characters:

  • After OTTO deploys a heading change, always verify using View Page Source rather than browser Inspect Element — the inspector renders entities automatically and can mask encoding problems.
  • Use GSC URL Inspection → Test Live URL as your definitive check for what Googlebot sees.
  • If your site uses a page builder such as Elementor, be aware that some builders manage heading output differently; confirm optimizations render correctly in both the builder preview and the live source.

🆘 Need More Help?

If you need further assistance, open the chat widget in the bottom-right corner of the platform and type human teammate to be connected with a member of our team.