HTML Worksheet: Practice Test
Code tip (Read the code like a browser): Find the topic of the question: tags, headings, lists, links, images, structure or comments. Read the code line by line, the way a browser would. Count carefully: tags opened and closed, items, lines, paragraphs.
NameDateTime takenScore ___ / 40
- 1.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h6> or <h4>? (a) <h3> (b) <h4> (c) <h2> (d) <h6>
-
2.📋 What number does the browser show next to “Jamun”?
<ol start="4">
<li>Guava</li>
<li>Mango</li>
<li>Banana</li>
<li>Orange</li>
<li>Jamun</li>
<li>Litchi</li>
</ol> -
3.🔍 Which line is missing its closing tag?
line 1: <small>I love mangoes.
line 2: <h2>Fun facts</h2>
line 3: <p>Our school trip</p> (a) line 2 (b) line 3 (c) line 1 - 4.True or false: HTML on its own cannot add up two numbers. (a) False (b) True
- 5.True or false: a web browser turns HTML into a page. (a) True (b) False
-
6.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>My Hobbies</title>
</head>
<body>
<h1>Easy snacks</h1>
<p>We won by 5 runs.</p>
</body>
</html> (a) We won by 5 runs. (b) Easy snacks (c) body (d) My Hobbies -
7.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Roses are red</p> -
8.💬 Which text will NOT show on the page?
<p>I love mangoes.</p>
<!-- <p>Good morning!</p> -->
<p>My pets</p>
<p>Rain today</p> (a) My pets (b) Rain today (c) I love mangoes. (d) Good morning! -
9.🔗 Where does this link open?
<a href="https://example.com">About us</a> (a) in a new tab (b) in the same tab - 10.🖼️ Why do we add alt text to an image? (a) to load it faster (b) to colour it (c) to make it bigger (d) to describe the image
- 11.📋 Which list tag lists steps in order? (a) <li> (b) <ol> (c) <ul>
- 12.📄 Where does <style> go: in the head or in the body? (a) in the body (b) in the head
- 13.🔠 Which heading shows the BIGGEST text: <h6>, <h1>, <h2> or <h4>? (a) <h4> (b) <h6> (c) <h1> (d) <h2>
- 14.📋 Which list shows the steps of a recipe best? (a) <br> (b) <ul> (c) <ol> (d) <hr>
-
15.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="350"> -
16.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<p>I love mangoes.</p>
<p>Rain today</p> - 17.Which of these has a closing tag? (a) <img> (b) <br> (c) <p> (d) <hr>
-
18.🔗 Which address opens when you click this link?
<a href="quiz.html">Visit the site</a> (a) Visit the site (b) about.html (c) quiz.html (d) games.html - 19.🔠 Which heading shows the BIGGEST text: <h1>, <h2>, <h4> or <h3>? (a) <h3> (b) <h4> (c) <h2> (d) <h1>
- 20.🔠 Which heading shows the SMALLEST text: <h4>, <h5>, <h3> or <h1>? (a) <h3> (b) <h4> (c) <h1> (d) <h5>
- 21.True or false: HTML on its own can count button clicks. (a) True (b) False
- 22.🔠 Which tag is the least important heading? (a) <h6> (b) <h1> (c) <h3> (d) <p>
- 23.🏷️ Which is the closing tag for <p>? (a) <p/> (b) <p> (c) </p> (d) <\p>
- 24.💬 How does an HTML comment start? (a) // (b) # (c) <!-- (d) /*
- 25.True or false: in <img>, src names the picture file. (a) True (b) False
- 26.🏷️ Is </title> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 27.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
- 28.🏷️ What does a closing tag have that an opening tag does not? (a) a dot . (b) a slash / (c) a hash # (d) a dollar $
-
29.🔗 Which words do you click on?
<a href="https://example.com">About us</a> (a) href (b) About us (c) Contact us (d) https://example.com -
30.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>The red kite</p>
<!-- <p>Cricket is fun.</p> --> -
31.📝 On how many lines does the browser show this paragraph?
<p>Roses are red<br>Rivers flow</p> - 32.📝 Does <title> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 33.Which of these is an opening tag? (a) </p> (b) </h1> (c) </b> (d) <title>
- 34.Which of these goes in the body? (a) <a> (b) <link rel="stylesheet"> (c) <title> (d) <meta charset="utf-8">
- 35.📄 Where does <ul> go: in the head or in the body? (a) in the head (b) in the body
-
36.🔗 Which words do you click on?
<a href="maths.html">Contact us</a> (a) href (b) Contact us (c) maths.html (d) Visit the site - 37.True or false: HTML on its own can make a form. (a) True (b) False
- 38.Which of these is an empty tag? (a) <p> (b) <meta> (c) <ul> (d) <b>
- 39.📄 Where does the text of <title> appear? (a) at the bottom (b) on the browser tab (c) nowhere (d) in a big heading
-
40.🔍 One closing tag is missing. Which one?
<h2>I love mangoes.</h2>
<p>My best friend</p>
<em>Cricket is fun. (a) </p> (b) </h2> (c) </em> (d) </b>
Answer key
- <h2>
- 8
- line 1
- True
- True
- Easy snacks
- 2
- Good morning!
- in the same tab
- to describe the image
- <ol>
- in the head
- <h1>
- <ol>
- 350
- 1
- <p>
- quiz.html
- <h1>
- <h5>
- False
- <h6>
- </p>
- <!--
- True
- a closing tag
- Yes
- a slash /
- About us
- 1
- 2
- has a closing tag
- <title>
- <a>
- in the body
- Contact us
- True
- <meta>
- on the browser tab
- </em>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids