Module 5: Links and Navigation
Email, Telephone, and Download Links
Use mailto, tel, and download links for actions that match their URL schemes.
The anchor element can link to more than web pages. The mailto: scheme opens the visitor’s configured email application, while tel: can offer a phone number to a device that supports calling.
<a href="mailto:hello@example.com">Email the team</a>
<a href="tel:+911234567890">Call the support desk</a>
<a href="/files/assignment.pdf" download>Download the assignment</a>
A mailto: link can include subject and body query parameters, but long or sensitive content should not be placed in a URL. A tel: link should use a number formatted for the intended audience. Display a readable number as the link text.
The download attribute asks the browser to download a resource instead of navigating to it. Its behavior can depend on the browser, URL origin, headers, and server configuration. Do not assume that every cross-origin file can be forced to download by adding the attribute.
For downloadable files, provide the file type and size when that information helps visitors decide whether to download it. A link should never claim to download a file that is missing or inaccessible.