Add Parameters to MailTo Link in HTML
In the MailTo link in HTML, you can add the below parameters:
- subject - for the subject line,
- cc - for sending a carbon copy,
- bcc - for sending a blind carbon copy,
- body - for the message's body text.
MailTo link in HTML Example
In this example, you can use To, CC, BCC, Subject, and Body in MailTo
link in HTML
<a href="mailto:email@example.com?cc=secondemail@example.com, anotheremail@example.com, &bcc=lastemail@example.com&subject=Mail from our debug.to&body=Welcome to debug.to">Send Email</a>
Output
Add a subject in the MailTo link in HTML
To add a subject to MailTo
link, you can use the below code:
<a href="mailto:email@example.com?subject=Mail from our debug.to">Send Email</a>
Add a body in the MailTo link in HTML
To add a body to MailTo
link, you can use the below code:
<a href="mailto:email@example.com?body=Welcome to debug.to">Send Email</a>
Add a CC mail in the MailTo link in HTML
To add a CC to MailTo
link, you can use the below code:
<a href="mailto:email@example.com?cc=secondemail@example.com, anotheremail@example.com">Send Email</a>
Add a BCC mail in the MailTo link in HTML
To add a BCC to MailTo
link, you can use the below code:
<a href="mailto:email@example.com?bcc=lastemail@example.com">Send Email</a>