🌐HTML Element
Also known as HTML Tag, Element, Tag
One piece of a web page, like a heading or a link, marked by tags.
Think of it like
It is like a box with a label. The label says what is in it, like a title or a picture.
Example
Lucy writes <h1>Opening hours</h1> at the top of her page. The browser shows it as the big main heading.
Why it matters
Every web page is built from elements. CSS styles them and JavaScript changes them, one element at a time.
Definition
Example code
html
<p>We open at <strong>9am</strong>.</p>Common mistake
Key takeaways
- 1Open and close. Most elements wrap content in two tags.
- 2The name means something. h1 is a heading, a is a link.
- 3Boxes in boxes. Elements nest inside each other.