Skip to content
FunnelGuard

Fix guide by FunnelsGuard

Email obfuscation breaking mailto and tel links: how to fix it

OPS-119Medium impactPartlyBy FunnelGuardPublished Updated
On this page

What this issue is

Spam bots scrape web pages for email addresses. To stop them, some CDNs, security plugins and themes obfuscate addresses. That means they swap the plain address in your HTML for an encoded string. A small script in the visitor's browser decodes it again.

The trick works only if the script runs. On Cloudflare, the feature is called Email Address Obfuscation and the script is /cdn-cgi/scripts/5c5dd728/cloudflare-static/email-decode.min.js. If a JavaScript optimiser, a cache rule, an ad blocker or a consent tool stops that script, the link breaks. Some tools also touch tel: links or phone numbers, or rewrite links inside forms and buttons, which is harder to spot.

Typical symptoms: a link that reads [email protected], a mailto link that opens an email with a garbled address, or a click-to-call button that does nothing.

Why it costs you leads or sales

Many visitors, especially on mobile, prefer to tap an email or phone link instead of filling in a form. If the link is broken, they leave or go to a competitor. You get no error and no alert, because nothing fails on the server. The page loads fine.

It also hurts tracking. If you count clicks on mailto: and tel: links as conversions in GA4 or Google Ads, a rewritten link may not match your trigger, so those conversions silently drop.

How a rewritten link loses the contact
  1. Visitor lands on pagePage loads normally
  2. CDN rewrites addressEmail replaced with encoded string
  3. Decode script runsBlocked, delayed or removed
  4. Visitor taps linkShows [email protected] or does nothing
  5. Enquiry sentNever happens

The page looks normal, but the decode step fails, so the visitor cannot reach you.

A contact link that does nothing

The visitor taps the link, but the broken script means nothing happens.

How to check if your site has it

Check your links by hand
  1. View the page source

    Open your contact page, press Ctrl+U (Cmd+Option+U on Mac) and search for mailto and tel:. If you see /cdn-cgi/l/email-protection or data-cfemail instead of your address, it is being obfuscated.

  2. Compare with the live page

    Open the page normally and look at the visible link text. Text such as [email protected] means decoding failed.

  3. Click and tap every link

    Click each email and phone link on desktop, then tap them on a real phone. Your mail app or dialler should open with the right address or number.

  4. Test with an ad blocker and with JavaScript off

    Many visitors use blockers. If the link breaks, the setup is fragile even if it works for you.

  5. Check the network tab

    In browser developer tools, open Network and reload. Look for email-decode.min.js. A blocked or failed request explains the break.

How to fix it

The most reliable fix is to stop rewriting the links that matter for conversion. Publicly listed sales contacts are usually already known to spammers, so the protection gives little benefit compared with the risk of lost enquiries.

Turn off or bypass obfuscation
  1. Cloudflare: switch it off

    In the Cloudflare dashboard choose your domain, then Scrape Shield, and set Email Address Obfuscation to Off. Menu names can vary slightly by plan and dashboard version.

  2. Or skip specific pages

    Use a Configuration Rule for the URL paths that hold your contact links and turn Email Obfuscation off there.

  3. Purge the cache

    Purge the CDN cache so pages are served without the rewritten markup.

  4. Opt out a single address

    Wrap it in the Cloudflare exclusion comments: <!--email_off-->...<!--/email_off-->.

Exclude one address from Cloudflare obfuscationhtml
<!--email_off-->
<a href="mailto:sales@example.com">sales@example.com</a>
<!--/email_off-->
Before and after the fix

Obfuscation on

  • Link text reads [email protected]
  • Tapping the link does nothing when the script is blocked
  • Link clicks missing from analytics

Obfuscation off for contact links

  • Real address in the HTML
  • Mail app and dialler open every time
  • Click events counted as expected

How to confirm it's fixed

Fix verification
  • View source shows the plain mailto: and tel: values
  • No data-cfemail or /cdn-cgi/l/email-protection in the contact markup
  • Link text shows the real address, not [email protected]
  • Links work on desktop and a real phone
  • Links work with an ad blocker on
  • Click events appear in GA4 DebugView or your tag tool
  • Checked header, footer, popups and sticky bars

How to prevent it happening again

Prevention habits
  • Note which CDN, security and optimisation features are on, and who owns them
  • After any CDN, plugin or theme change, click your contact links again
  • Use a Configuration Rule instead of a site-wide setting when you need the feature elsewhere
  • Keep the main contact route independent of JavaScript decoding
  • Re-test after migrating hosts or switching DNS

How FunnelGuard handles this

FunnelGuard detects this issue only partly. A robot visitor runs your real customer journeys on a schedule and checks each step. If a rewritten link makes a journey step fail, for example a click on a contact or call button that no longer works, the step fails and you get one alert with a screenshot and a likely cause after a re-check from a second region.

What it does not do: it does not scan every page for rewritten mailto and tel links, and it does not open your mail app or phone dialler. A scrambled link on a page that is not part of a monitored journey can go unnoticed.

Cover the rest by hand: use the checks above after any CDN or plugin change, and add your main contact page to a journey so the button is exercised on every run. The Free plan includes 1 site and 2 journeys with daily checks and no card, and every paid plan has a 3-day free trial.

Common questions

The answers below cover the questions people ask most often about this problem.

Questions people ask

Why does my email link show [email protected]?

That text is a placeholder added by an email obfuscation feature, usually Cloudflare Email Address Obfuscation. A script should swap it for your real address in the browser. If the script is blocked or fails to load, the placeholder stays.

How do I turn off Cloudflare Email Address Obfuscation?

In the Cloudflare dashboard, select your domain, open Scrape Shield and set Email Address Obfuscation to Off. Then purge the cache. You can also exclude one address with <!--email_off--> comments around it.

Why is my tel link not working on mobile?

Check whether a CDN, plugin or script has rewritten the number, and view the page source to see the real href. A rewritten or broken href stops the dialler opening. Also confirm the number uses the format tel:+441234567890 with no spaces.

Does email obfuscation hurt conversions?

It can. If the decode script is blocked by an ad blocker, a JavaScript optimiser or a consent tool, the link breaks and visitors cannot contact you. You will not see an error, so lost enquiries go unnoticed.

Do I need email obfuscation at all?

Not for a sales address that is already public. Obfuscation only slows basic scrapers, and the cost is a possible broken link. A contact form with spam protection is a safer main route.

How can I test if my mailto links work?

View the page source and check the href holds the plain mailto: address. Then click it on desktop and tap it on a phone, with and without an ad blocker. Check header, footer and popup links too.

Can FunnelGuard detect rewritten mailto links?

Only partly. It catches a failing step in a monitored journey, such as a contact button that stops working. It does not scan every page for rewritten links or open your mail app, so check those by hand.

Does FunnelGuard catch this?

Partly

FunnelGuard checks part of this.

Stop finding out from your customers

FunnelGuard runs your real forms and checkouts on a schedule, checks the tracking and the leads behind them, and alerts you once, with a screenshot. Try any paid plan free for 3 days.