Articles → HTML → MailTo in html

MailTo in html






Purpose





Syntax


<a href="mailto:email_address">Link text</a>




<a href="mailto:email_address?subject=subject_text&CC=email_address&BCC=email_address&body=body_text">Link text</a>





Example


<html>
<head>
    <title>MailTo Demo</title>
</head>
<body>
   <a href="mailto:gyansangrah@gyansangrah.com?subject=Welcome to gyansangrah&CC=info@gyansangrah.com;others@gyansangrah.com&BCC=donotreply@gyansangrah.com&body=This is the test message">Click here to open default mail client</a>
</body>
</html>





Output



Click to Enlarge


Browser support


Internet ExplorerFirefoxChromeSafariOperaEdge
YesYesYesYesYesYes



Posted By  -  Karan Gupta
 
Posted On  -  Wednesday, October 26, 2016
 
Updated On  -  Monday, October 09, 2017

Query/Feedback


Your Email Id  
 
Subject 
 
Query/FeedbackCharacters remaining 250