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 part holds everything you see on the page? (a) the doctype (b) the head (c) the title (d) the body
-
2.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="moon.png" alt="The full moon" width="50"> (a) Our school bus (b) moon.png (c) width (d) The full moon -
3.📝 How many paragraphs does this code make?
<p>Cricket is fun.</p>
<h2>Our school trip</h2>
<h2>Good morning!</h2>
<h2>My pets</h2> - 4.Which of these goes in the head? (a) <p> (b) <table> (c) <a> (d) <style>
- 5.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <br> (c) <ol> (d) <hr>
-
6.🔍 One closing tag is missing. Which one?
<h2>Hello, world!</h2>
<h1>My pets
<small>The red kite</small> (a) </small> (b) </u> (c) </h2> (d) </h1> -
7.🔍 Which line is missing its closing tag?
line 1: <h3>My best friend</h3>
line 2: <u>I love mangoes.</u>
line 3: <h1>Good morning! (a) line 1 (b) line 3 (c) line 2 -
8.📋 What number does the browser show next to “Mango”?
<ol>
<li>Banana</li>
<li>Grapes</li>
<li>Litchi</li>
<li>Mango</li>
</ol> - 9.🏷️ Is <h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
10.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="150"> (a) A tiger asleep (b) tiger.jpg (c) A red kite (d) width - 11.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h2> or <h5>? (a) <h2> (b) <h1> (c) <h6> (d) <h5>
- 12.📄 Where does the text of <title> appear? (a) on the browser tab (b) nowhere (c) in a big heading (d) at the bottom
-
13.💬 How many paragraphs show on the page?
<!-- <p>Fun facts</p> -->
<p>My best friend</p>
<p>I love mangoes.</p>
<!-- <p>My pets</p> --> - 14.True or false: a web browser hosts websites online. (a) False (b) True
-
15.🖼️ How many pixels wide is the picture drawn?
<img src="bus.jpg" alt="Our school bus" width="50"> - 16.🔢 In a basic web page file, which comes first: “</body>” or “</html>”? (a) </html> (b) </body>
- 17.🔢 In a basic web page file, which comes FIRST? (a) </html> (b) </body> (c) <!DOCTYPE html> (d) <head>
- 18.🔠 How many heading levels does HTML have? (a) 3 (b) 4 (c) 6 (d) 10
- 19.Which of these has a closing tag? (a) <p> (b) <input> (c) <hr> (d) <meta>
- 20.📝 Does <input> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
-
21.📋 How many items does this list show?
<ol>
<li>Orange</li>
<li>Guava</li>
<li>Litchi</li>
<li>Papaya</li>
<li>Jamun</li>
<li>Banana</li>
</ol> - 22.🏷️ Every HTML tag starts with which sign? (a) [ (b) ( (c) < (d) {
- 23.True or false: <ul> shows bullet points. (a) True (b) False
- 24.True or false: HTML on its own can add up two numbers. (a) False (b) True
-
25.🔍 Which line is missing its closing tag?
line 1: <u>I love mangoes.</u>
line 2: <h1>My best friend
line 3: <h3>Rain today</h3> (a) line 2 (b) line 3 (c) line 1 - 26.🔠 Which heading shows the SMALLEST text: <h5>, <h1>, <h6> or <h4>? (a) <h1> (b) <h5> (c) <h4> (d) <h6>
-
27.🔠 How many headings are in this code?
<h1>Rain today</h1>
<h4>My best friend</h4>
<h3>I love mangoes.</h3>
<h3>My pets</h3>
<h2>The red kite</h2> - 28.🔠 Which heading shows the SMALLEST text: <h6>, <h4>, <h1> or <h3>? (a) <h6> (b) <h3> (c) <h4> (d) <h1>
-
29.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>All about me</h1>
<p>Mars is red.</p>
</body>
</html> (a) body (b) Cricket Club (c) Mars is red. (d) All about me - 30.True or false: <ol> lists steps in order. (a) False (b) True
- 31.True or false: a web browser stores a website’s files. (a) False (b) True
- 32.🔠 Which tag is the least important heading? (a) <h6> (b) <p> (c) <h1> (d) <h3>
- 33.🔠 Which heading shows the SMALLEST text: <h2>, <h6>, <h3> or <h1>? (a) <h1> (b) <h3> (c) <h6> (d) <h2>
-
34.📝 On how many lines does the browser show this paragraph?
<p>Roses are red<br>Birds sing</p> -
35.📝 How many paragraphs does this code make?
<p>My pets</p>
<p>Rain today</p>
<p>My pets</p>
<p>Hello, world!</p>
<p>Rain today</p>
<p>I love mangoes.</p> - 36.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h6> or <h2>? (a) <h4> (b) <h6> (c) <h2> (d) <h1>
- 37.📄 Can HTML on its own keep a high score? (a) No (b) Yes
- 38.🔠 Which heading shows the BIGGEST text: <h6>, <h5>, <h3> or <h1>? (a) <h5> (b) <h6> (c) <h1> (d) <h3>
- 39.📋 Which list suits a shopping list in any order? (a) <ul> (b) <br> (c) <ol> (d) <hr>
-
40.📋 How many items does this list show?
<ul>
<li>Orange</li>
<li>Guava</li>
<li>Banana</li>
<li>Jamun</li>
</ul>
Answer key
- the body
- The full moon
- 1
- <style>
- <ol>
- </h1>
- line 3
- 4
- an opening tag
- A tiger asleep
- <h1>
- on the browser tab
- 2
- False
- 50
- </body>
- <!DOCTYPE html>
- 6
- <p>
- an empty tag
- 6
- <
- True
- False
- line 2
- <h6>
- 5
- <h6>
- All about me
- True
- False
- <h6>
- <h6>
- 2
- 6
- <h1>
- No
- <h1>
- <ul>
- 4
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids