The <a> (anchor) tag is what makes the web a web — it connects pages together. Without links, every page would be an island.
<a href="https://www.example.com">Visit Example</a>
href (HyperText REFerence) — the destination URL. Without it, <a> is not a hyperlink.Point to a page on a different website:
<a href="https://www.google.com">Google</a>
Always use full URLs (including https://) for external sites.
Point to a page within the same website:
<!-- Link to about.html in the same folder -->
<a href="about.html">About</a>
<!-- Link to a file in the parent folder -->
<a href="../index.html">Home</a>
Relative paths change depending on where the current file sits in the folder structure.
Add target="_blank". Always pair it with rel="noopener noreferrer" for security:
<a href="https://www.google.com" target="_blank" rel="noopener noreferrer">Google (new tab)</a>
Use an element's id as the href target to scroll to that part of the page:
<a href="#contact">Jump to Contact</a>
...
<h2 id="contact">Contact Us</h2>
This is how "Back to top" links and table-of-contents navigation work.
In the starter index.html you have two empty sections. Your tasks:
<a href="https://www.wikipedia.org">) in a <nav>.target="_blank".<a href="#about"> in the nav.<section id="about"> below the nav with an <h2> and a <p>.The anchor tag syntax is: <a href="URL">link text</a>