Home / Learn HTML / HTML Practice Challenges
HTML Practice Challenges
Learn by doing. Each challenge gives you starter code and a goal. Write your own answer in the editor.
About this lesson
Reading is not enough: you learn HTML by typing it. These challenges go from beginner to hard. Try each one yourself in the editor before looking at any hint.
Write your answer in the editor and press Check my answer. The page tests your code against the goal and shows what is right and what is missing. Solved challenges are saved in your browser and earn you badges.
Level 1: Beginner
Goal: Show your name as the biggest heading.
- Has an h1
- The h1 has some text
Goal: Add a paragraph with two sentences.
- Has a paragraph
- The paragraph has two sentences
Goal: Add a bullet list with 4 items.
- Has a bullet list (ul)
- Has 4 list items
Goal: Make a link to google.com that opens in a new tab.
- Link goes to google.com
- Opens in a new tab
- Link has text
Goal: Show https://placehold.co/200x100 and give it good alt text.
- Image source is placehold.co
- Alt text has at least 3 letters
Level 2: Easy
Goal: Make a table with the columns Name and City and 3 rows of friends.
- Has a table
- Has 2 or more header cells (th)
- Has 4 rows in total
Goal: Write an ordered list of 5 steps to make tea.
- Has an ordered list (ol)
- Has 5 steps
Goal: Make a form with a name box, an email box and a submit button. Connect each label to its box.
- Has a form
- Has a name input
- Has an email input
- Has a submit button
- Has 2 labels connected with for
Goal: Make a nav with 3 links.
- Has a nav element
- Has 3 links inside nav
Goal: Build a page with a header, a main and a footer in this order.
- Has a header
- Has a main
- Has a footer
- Header comes before main
- Main comes before footer
Level 3: Medium
Goal: Write a full page with a doctype, language, charset, viewport, a title and one heading.
- Starts with the doctype
- html has a lang attribute
- Has meta charset
- Has the viewport meta
- Title has text
- Has one h1
Goal: Show a picture with a caption using the right elements.
- Has a figure with an image
- Image has alt text
- Has a figcaption inside the figure
Goal: Make 2 questions that open and close, using details and summary.
- Has 2 details elements
- Each has a summary
Goal: Add a video with the play controls and a poster picture.
- Has a video with controls
- Has a poster attribute
- Has a video source
Goal: Make a labelled dropdown with 3 city options.
- Has a select
- Has 3 options
- Label is connected with for
Goal: Make a description list with 2 terms and their meanings.
- Has a dl
- Has 2 terms (dt)
- Has 2 descriptions (dd)
Goal: Embed a page with an iframe that has a title.
- Has an iframe
- Iframe has a src
- Iframe has a title