Ad space (banner)
🎨HTML & CSS Lessons
Lesson 3 / 50

Lists and Links

In this lesson you'll learn how to build lists and links so you can express menus and navigation between pages. This is for people searching "HTML how to make a list" or "HTML link href."

Lining up items with <li> inside a <ul> (bulleted) or <ol> (numbered) list lets you neatly organize things like a menu or a set of steps. It's the basic building block for grouping multiple items together, like a shopping list or a table of contents. You create a link with <a href="URL">.

The sample code lines up three <li> items inside a <ul> to build a list of favorite languages, and places a link with <a href="URL">. href specifies the destination address, and the text wrapped by the tag becomes a clickable link string.

A common beginner stumbling block is writing something other than <li> directly inside a <ul> or <ol>. List tags are meant to have only <li> as their direct children — breaking this rule can cause the appearance to fall apart. Also be careful: forgetting href means the link won't function as one.

Navigation menus and page-to-page movement are all built on this same mechanism. From guiding visitors to different pages on a site, to referencing external sites, links are the most fundamental feature underpinning the entire web.

HTML & CSS
OUTPUT

💡 The preview runs entirely on this page — nothing is sent externally.

Ad space (banner)
Ad space (in-article)