Recently one of our readers asked us how to add an email address in WordPress? Creating a link to an email address allows users to send you an email with a click. In this article, we will show you how to link to an email address in WordPress.
Video Tutorial
If you don’t like the video or need more instructions, then continue reading.
Creating a Link to an Email Address in WordPress
Adding a link to an email address is very much like adding other links in WordPress. Take a look at our guide on how to add a link in WordPress.
When adding a link to any other web page, you usually add http://
or https://
followed by rest of the url. For example, http://www.example.com
Similarly when adding a link to an email address, you need to replace the http part with mailto: prefix followed by the email address you want to link to. Here is a example:
mailto:john@example.com
Here is how you will add it in a WordPress post.
Select the text you want to add the link to and then press CTRL+K (Command+K on Mac) or click on the ‘Insert Link’ button in the post editor.
This will bring up the insert link popup where you need to add your mailto link. Click on the apply button to close the insert link popup.
As you can see in the animation above, we added a link to an email address. WordPress will automatically detect that the text you are trying to link is an email address and will add the mailto: prefix to the email address.
You can add an email link to any text. If the text is not a valid email address then you will need to add your complete link. Like this:
How to Manually Add an Email Link in WordPress Using HTML
If you want to add an email link in a text widget or a WordPress theme file, then you will need to add link by writing the HTML.
Here is how you will add an email link using HTML:
<a href="mailto:john@example.com">Email Me</a>
Why You Should Avoid Adding Email Links in WordPress Posts and Pages?
The downside of adding an email link is that the email address becomes publicly visible. This allows email scraping bots to collect it, which means you will get tons of spam on those email addresses.
Another disadvantage is that users are less likely to switch applications (from browser to their email client) to send an email. Most users may not want to use their primary email address to send out emails.
You can easily avoid this by adding a contact form instead of adding an email link.
We recommend using WPForms. It is the most beginner friendly contact form plugin in the market.
See our step by step tutorial on how to create a contact form in WordPress.
Another way to beat email bots is by encoding email addresses. Check out our tutorial on how to protect emails from spammers with WordPress email encoder.
We hope this article helped you learn how to link to an email address in WordPress. You may also want to see our guide on 14 tips for mastering the WordPress visual editor.
If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.
Kelly
I’ve got the email link established and it’s loaded to my “contact us” page. So when I load the page up externally and click the link, I get a “Page Not Found” because it’s using my email address link as a regular link to another page on my site, of course doesn’t exist. Can you tell me what I did wrong? Thank you!
Deneen
I can’t figure out how to view the emails that are sent via my “Contact Me” page. I keep sending test emails, but they aren’t showing up. How do I link my website’s email address to my contact me forms?
WPBeginner Support
It would depend on the tool you are using and where you are sending the messages, if you are not seeing the emails, the most common reason would be how WordPress sends emails. To get past that you would want to take a look at our guide below:
https://www.wpbeginner.com/plugins/how-to-set-up-wp-mail-smtp-with-any-host-ultimate-guide/
Admin
Gerald-in-Crete
I absolutely endorse your simple and direct explanations. I am referring to how to insert an e-mail hyperlink in a posting.
WPBeginner Support
Glad you found our content helpful
Admin
Mima
Hello there,
Thank you for providng such great support and guidance for beginners – most helpful. Please can you advise what the string is for mailto links which pre-populate the subject line. Is it as below?:
“mailto:john@example.com?subject=”
Thank you in advance for your response,
Mima
WPBeginner Support
For adding content to the subject line you have the correct code for the HTML method.
Admin
Sebastian Kayser
Excellent and very helpful article. Thank you!
WPBeginner Support
You’re welcome
Admin
Jessica
How can I safely allow people to send .jpeg files to me? I turn them into art and I don’t know how to allow them to upload a picture. Is the best way to let them email me a photo?
WPBeginner Support
Hi Jessica,
You can use WPForms to create a contact form with a file upload field. This will allow users to upload a file and send it to you with rest of the message. For instructions, please see how to add file upload field to a form.
Admin
Lauren
Thank you! This was very helpful and straight to the point.
Marlene
Hi there
I am also creating the email links in the WP site text as demonstrated, yet, when we click on them (front page) they go to Chrome and do not create and email?
What am I doing wrong?
Kate
Hello
Thank you for this…however, i have these standing OK on the site, but they dont link to actually make an email – all they do at the bottom is show the address. On mobile it works fine…
Johnnie Rhodes
Thank you!
saramike
useful link
SUNIL
Thank you
Nathan
Good information and details with perfect photos
matingholami
Great Post,
But I’m searching for something different, could U help me?
I want registered users to be allowed to write posts but not allowed to publish them, I mean they can write posts but every post written by users must be checked and edited and published by admins
although I want to control admin area interface, I want to be able to disable admin widgets or show messages to them through the admin area
WPBeginner Support
Please see our guide on how to allow users to submit posts to your WordPress site.
Admin
Mohammad Sharfuddin
Install User Roles and Capabilities Plug-in