How to Hide (Encode) contacts on WordPress website from Crawlers and Bots
- Email Addresses Encoding
- Phone Numbers Encoding
- Encoder Obfuscation Mode
- Encoding with Shortcodes
- Checking the Encoding
The CleanTalk Anti-Spam plugin can encode email addresses and phone numbers on your website. This makes them unreadable to spambots that scan public pages for contact information.
Hiding emails and phone numbers prevents your data from being harvested and added to spam mailing lists or used for unwanted calls. Visitors will still be able to see and use your contact details, but bots will only see encoded or partially hidden versions.
You can enable this option in the Contact Data Encoding section here:
- WordPress Dashboard → Settings → Anti-Spam by CleanTalk → Advanced settings
Email Addresses Encoding
To encode the email addresses, check the Encode email addresses option. The plugin will encode all email addresses on your website's pages.
Original view:
Encoded view:
After clicking, the address will be decoded:
Phone Numbers Encoding
Check the Encode phone numbers option to encode contact phone numbers.
Here are the requirements for the number format:
- Must start with a "+" symbol.
- Must contain at least 8 digits and fewer than 13 digits.
- Spaces, parentheses, and dashes are allowed between digits.
Examples of valid formats:
- +1 (234) 567-8901
- +12345678901
- +12 34 5678901
Phone numbers formatted correctly within an <a> tag with the "tel" property will also be encoded, for example:
<a href="tel:+11234567890">Call +1 (123) 456-7890</a>
Encoder Obfuscation Mode
This option determines how hidden email addresses and phone numbers appear on your site before they are decoded.
The display methods:
Blur effect
The contact information will be partially obscured with a blur effect:
Replace with "*"
The contact information will be partially replaced with asterisk (*) symbols:
Replace with custom text
The entire contact information will be replaced with custom text that you provide in the relevant settings field.
Result
Encoding Contact Data with a Shortcode and Hook for Third-Party Plugins
You can also encode contact data on your site via shortcodes and hooks. The guide is here.
Hooks For Changing the Encode Contact Data Option Phrases
Since the 6.52 version of the Anti-Spam by Cleantalk plugin, it is possible to change some of the Encode Contact Data option phrases. The guide is here.
How to Check If Email Encoding Is Working
- Open your webpage in your browser in Guest (Incognito) mode.
- Scroll down the page to the email address. Now you should see that the email is already encrypted.
To decrypt it, just click on it. If you hover the mouse pointer over the email, you will see the “This contact was encoded by CleanTalk. Click to decode” message. It is a hint for your website visitors. Be sure to test the encryption/decryption in Guest (Incognito) mode, because if you are authorized on the site, there will be no encryption.
Since version 5.184 of the Anti-Spam plugin, each email encoding is logged in your Anti-Spam Log with the status "Decoding approved".
If you haven't found the answer to your question, please contact our support team:
https://cleantalk.org/my/support/open
It would also be interesting
- Hooks For Changing the Encode Contact Data Option PhrasesHooks For Changing the Encode Contact Data Option Phrases Please note that the Anti-Spam plugin...
- Encoding Contact Data with a Shortcode and Hook for Third-Party PluginsEncoding Contact Data with a Shortcode and Hook for Third-Party Plugins Please note that the Anti-Spam...
- All Installation Manuals of CleanTalk Anti-Spam ServiceCleanTalk Anti-Spam Installation Guides Here you can find our plugin installation guides for popular...