On this page
HTML Quiz & Practice Exercises
HTML Quiz & Practice Exercises
Ready to test what you've learned? This HTML quiz and set of hands-on practice exercises cover tags, attributes, forms, semantic elements, and events. Use these to check your understanding before moving on to more advanced topics.
Why Practice Matters
Reading about HTML tags and attributes is only half the process — actually writing code reinforces memory and reveals gaps in understanding. This page pairs a scored HTML quiz with editable, hands-on coding exercises so you can practice immediately.
How to Use This Page
- Take the quiz below to test your theoretical knowledge
- Complete each coding exercise to practice writing real HTML/JS
- Compare your solution to the expected output described in each exercise
- Revisit earlier reference topics if you get stuck
Topics Covered in This Practice Set
| Area | What's Tested |
|---|---|
| Core Tags | Headings, paragraphs, lists, links |
| Semantic HTML | header, article, section, footer usage |
| Forms | Input types, labels, required fields |
| Attributes | id, class, data-*, alt |
| Events | onclick, oninput, addEventListener |
Try It Yourself
Complete the coding exercises below to put your HTML skills into practice.
Press Run to execute.
Create a signup form with fields for name, email, and password, each with a label. Add a submit button. Make the email and password fields required.
Press Run to execute.
Show expected output
A form with labeled name, email, and password inputs, submit button, and required validation on email and password.This is a self-check — compare your result with the expected output above.
The list below has incorrect nesting. Fix it so all <li> items are properly placed inside the <ul> tag.
Press Run to execute.
Show expected output
A valid <ul> containing three properly closed <li> elements, with no stray list items outside the list.This is a self-check — compare your result with the expected output above.
Was this page helpful?