Skip to content
Codemefy

Codemefy

CODEMEFY: YOUR DIGITAL CHATTER

Menu
  • HOME
  • Blog
  • ABOUT CODEMEFY
  • CONTACT
  • Home
  • Email marketing
  • How to Create Better Mailto Links and Edit Them in HTML
Email marketing HTML

How to Create Better Mailto Links and Edit Them in HTML

Adele BaltuonieneMarch 25, 2017August 8, 2023
mailto links - codemefy blog

Let’s talk about mailto links in emails. We’re not exactly head-over-heels in love with them, but hey, sometimes they’re our only option. Sure, we’d prefer to craft stunning landing pages and interactive web forms, but let’s face it—life isn’t always that glamorous. Not everyone has the fancy tools, abundant resources, or luxury of time to create those masterpieces. That’s when our trusty sidekick, the mailto link, swoops in to save the day! And hey, there are moments when all we need is a lone humble email link nestled snugly in a contact us bar. So, in this post, let’s learn how to create and customize mailto links.

Step One: Create a Mailto Link

I often get questions about adding mailto links in emails, so let’s have a look. Many email service providers will actually have email mailto functionality in their WYSIWYG, making it super easy for the user. However, if you need to add it in manually, you will need to add a bit of HTML code. Here’s how:

Please reply <a href=”mailto:insertemailaddress”>here</a>

The method outlined above will insert the mailto link in the word “here“.

Step 2: Add a Subject Line into the Mailto Link

Let’s go a step further. If you are using mailto links, try to give your email recipients a better user-experience by pre-populating the subject line in the mailto link. Here’s the bit of extra code you need to add into the link:

Please reply <a href=”mailto:insertemailaddress?subject=This is my subject line”>here</a>

Please note that you might need to add  %20 instead of spaces in the subject line.

Please reply <a href=”mailto:insertemailaddress?subject=This%20is%20my%20subject%20line”>here</a>

Step 3: Add Pre-Populated Body Text into the Mailto Email

It is also possible to add a bit of pre-populated body text in the mailto email message. Let’s say, you are creating an email message for a mailto link to capture registration confirmations. Thus, you’d like once the mailto email message to say, for example, “Yes, I would like to attend”. This way, your email recipient would just have to hit send. You can achieve that by adding &body to your HTML code:

Please reply <a href=”mailto:insertemailaddress?subject=This%20is%20my%20subject%20line&body=Yes%20I%20will%20attend”>here</a>

You might need to insert a line break in the body copy. You can do this by adding %0D%0A to your HTML code. Make sure you use correct HTML for the ampersand, question mark, equal signs, and double-quotes.

Bonus: Free HTML Editors

If you don’t have a tool to edit your HTML and you’re stuck with Notepad,  try to use a free HTML editor. Here are some links to online HTML editors:

  • HTML editor
  • HTML5 editor
  • HTML Online
Originally published in March 2017, updated in January 2023
Tagged Email Hack, HTML

Post navigation

Next

Next post:

Email Marketing Blogs: Learn More About Email Marketing For Free

email marketing blogs - codemefy Next post Email Marketing Blogs: Learn More About Email Marketing For Free

One thought on “How to Create Better Mailto Links and Edit Them in HTML”

  1. free HTML editor says:
    July 3, 2019 at 12:58 am

    Can you tell us more about this? I’d love to find out some
    additional information.

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Close
Menu
  • HOME
  • Blog
  • ABOUT CODEMEFY
  • CONTACT
Copyright All rights reserved

Address: 9812 Springfield road, Coldstream, BC, CA, V1B 3E2 | Contact: enquiries@codemefy.com

All information on this site is intended for entertainment purposes only. All reasonable efforts have been made to ensure the accuracy of the content. Codemefy may contain links to third party websites which are not under control of Codemefy.