Hyperlinks

A hyperlink is a clickable link that takes the user to another webpage, file, email address or place on the same webpage.

The HTML tag used to create a hyperlink is the anchor tag:

<a href="destination">Clickable text</a>
  • <a> is the anchor tag
  • href stores the address of the destination
  • Clickable text is the text the user selects

External hyperlinks

An external hyperlink takes the user to a different website.

<a href="https://www.bbc.co.uk">Visit BBC</a>

Internal hyperlinks

An internal hyperlink takes the user to another page in the same website.

<a href="contact.html">Contact Us</a>

Absolute and relative addresses

Address type Used for Example
Absolute address An absolute address includes the complete web address, including https://. It is normally used to link to another website. https://www.bbc.co.uk
Relative address A relative address links to a file or page within the same website. It does not include the full web address.
  • contact.html
  • pages/contact.html
  • cat.png
  • images/cat.png