What are attributes?
Attributes provide additional information about HTML elements.
Learn how websites are structured from the ground up using HTML. Build real pages while learning elements, attributes, links, images, forms, tables, semantic HTML and more.
Lesson 14 of 24
14 min learning time
Attributes provide additional information about HTML elements.
Common attributes include id, class, href, src, alt, title and name.
<p
id="intro"
class="text"
title="Introduction"
>
Welcome to HTML.
</p>
Practical Exercise
Create an element with id, class and title attributes.
Quick Check
Where are HTML attributes normally placed?