📄

Links

Beginner
60 XP
15 min
Lesson Content

Links

Links connect pages, like signposts or doors that take you somewhere else. In HTML, links are created with the <a> tag.

Basic Link

<a href="https://example.com">Visit Example</a>

The href attribute tells the browser where the link goes.

<p>Learn more: <a href="https://developer.mozilla.org">MDN Web Docs</a></p>
Example Code

Add two links: one to your favorite website and one to another lesson page.

<!DOCTYPE html>
<html>
  <head>
    <title>Links Practice</title>
  </head>
  <body>
    <nav>
      <!-- Add a link to https://example.com with text 'Example' -->
      
      <!-- Add a link to /lessons/html-introduction with text 'HTML Intro' -->
    </nav>
  </body>
</html>

Expected Output:

Example
Study Tips
  • Read the theory content thoroughly before practicing
  • Review the example code to understand key concepts
  • Proceed to the Practice tab when you're ready to code