a
Creates a hyperlink to a page, section, file, email or protocol.
Learn a, strong, em, code, span as part of the HTML element system: when to use it, how it fits inside a document and what mistakes to avoid.
Inline text
Inline elements work inside lines of text. They mark links, importance, emphasis, code, abbreviations and other small pieces of meaning.
The key is to choose elements for meaning. A word can look bold with CSS, but strong tells the document that the word is important.
a, strong, em, code, span. Meaning and neutral hooks inside a sentence: links, importance, emphasis, code and span. Syntax in context
Use inline elements only around the words that need meaning. Do not wrap whole layouts in inline tags.
<p> Learn <strong>semantic HTML</strong> before styling. Open the <a href="#live-lab">live lab</a> and edit the <code>h1</code>. Use <span class="highlight">span</span> only when you need a neutral inline hook. </p>
Good versus weak
<p> Learn <strong>semantic HTML</strong> before styling. Open the <a href="#live-lab">live lab</a> and edit the <code>h1</code>. Use <span class="highlight">span</span> only when you need a neutral inline hook. </p>
<p> <b>semantic HTML</b> <span onclick="location.href='lesson.html'">live lab</span> h1 </p>
Rules that matter
A link without href is not a useful hyperlink.
Use strong for importance. Use CSS for visual weight alone.
Use em when the stress of the sentence changes.
Use code for commands, tags, filenames and technical terms.
Use span when you need a styling or scripting hook and no meaningful element is available.
Production thinking
Beginners often ask why this is not just a div with styling. The reason is that HTML is read by browsers, search engines, screen readers and future developers. Clear meaning makes the page easier to use and maintain.
Real links are keyboard accessible by default and are announced as links. Clickable spans are not a substitute.
Inline markup is small, but it affects navigation, SEO anchors, documentation quality and conversion flows.
Live code lab
Edit the HTML or CSS, then use Run to refresh the preview. The preview is isolated, so links and forms stay inside this practice area.
Mini assignment
Practice assignment
Try it yourself
Self-check
Do not only read this page. Answer these questions out loud or write the answers in your own notes. If one answer feels vague, revisit the examples before moving on.