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.💬 How does an HTML comment start? (a) <!-- (b) # (c) /* (d) //
- 2.🔠 How many heading levels does HTML have? (a) 10 (b) 3 (c) 4 (d) 6
- 3.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h5> or <h1>? (a) <h1> (b) <h3> (c) <h6> (d) <h5>
- 4.📄 Can HTML on its own make tables? (a) No (b) Yes
- 5.🔠 Which tag is the least important heading? (a) <p> (b) <h6> (c) <h1> (d) <h3>
-
6.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="100"> (a) cake.jpg (b) map.png (c) kite.png (d) A red kite - 7.📋 Which tag goes around each item of a list? (a) <p> (b) <li> (c) <ul> (d) <ol>
-
8.🔍 Which line is missing its closing tag?
line 1: <strong>Fun facts
line 2: <h1>Hello, world!</h1>
line 3: <p>The red kite</p> (a) line 1 (b) line 3 (c) line 2 -
9.📋 Does this list show bullets or numbers?
<ol>
<li>Mango</li>
<li>Orange</li>
</ol> (a) numbers (b) bullets - 10.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as 5 spaces (c) as a new line (d) as one space
- 11.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to load it faster (c) to colour it (d) to describe the image
- 12.Which of these is an opening tag? (a) </b> (b) </h1> (c) </p> (d) <body>
-
13.🔍 Which line is missing its closing tag?
line 1: <p>Fun facts
line 2: <h3>My pets</h3>
line 3: <h2>I love mangoes.</h2> (a) line 2 (b) line 1 (c) line 3 -
14.💬 Which text will NOT show on the page?
<!-- <p>Hello, world!</p> -->
<p>The red kite</p>
<p>My best friend</p> (a) The red kite (b) My best friend (c) Hello, world! -
15.🔍 Which line is missing its closing tag?
line 1: <strong>Good morning!</strong>
line 2: <u>My best friend
line 3: <em>The red kite</em> (a) line 1 (b) line 3 (c) line 2 -
16.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>Cricket is fun.</p>
<!-- <p>Fun facts</p> --> - 17.True or false: in <img>, alt tells which image to load. (a) False (b) True
-
18.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="250"> (a) width (b) A happy dog (c) Birthday cake (d) cake.jpg - 19.🏷️ HTML marks up text using ___. (a) wires (b) pixels (c) keys (d) tags
-
20.💬 Which text will NOT show on the page?
<p>Rain today</p>
<p>Hello, world!</p>
<!-- <p>Cricket is fun.</p> -->
<p>Good morning!</p> (a) Rain today (b) Good morning! (c) Cricket is fun. (d) Hello, world! - 21.Which of these goes in the body? (a) <a> (b) <title> (c) <style> (d) <meta charset="utf-8">
-
22.🖼️ Which picture file does the browser load?
<img src="bus.jpg" alt="Our school bus" width="350"> (a) Our school bus (b) tiger.jpg (c) fort.jpg (d) bus.jpg - 23.Which of these is a closing tag? (a) <b> (b) <p> (c) <title> (d) </b>
- 24.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h1> or <h2>? (a) <h4> (b) <h3> (c) <h1> (d) <h2>
- 25.True or false: HTML on its own can make a form. (a) False (b) True
- 26.True or false: in <img>, height sets how tall it is. (a) False (b) True
- 27.🔠 Which tag is used for the main title on a page? (a) <h1> (b) <p> (c) <h6> (d) <br>
- 28.True or false: <title> goes in the body. (a) False (b) True
-
29.📋 How many items does this list show?
<ol>
<li>Grapes</li>
<li>Papaya</li>
<li>Mango</li>
<li>Guava</li>
</ol> - 30.🔤 In “HTML”, what does the L stand for? (a) Language (b) Laptop (c) Link (d) Line
- 31.Which of these is an opening tag? (a) </b> (b) </p> (c) <h1> (d) </li>
-
32.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="dog.jpg" alt="A happy dog" width="200"> (a) The full moon (b) dog.jpg (c) A happy dog (d) width -
33.🔍 Which line is missing its closing tag?
line 1: <h3>Hello, world!</h3>
line 2: <p>Rain today</p>
line 3: <b>Cricket is fun. (a) line 2 (b) line 1 (c) line 3 - 34.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
35.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>My best friend</p>
<p>I love mangoes.</p>
<p>Rain today</p> (a) Our school trip (b) My best friend (c) I love mangoes. (d) Rain today - 36.True or false: <meta charset="utf-8"> goes in the head. (a) True (b) False
- 37.🧩 An opening tag + content + a closing tag together make an ___. (a) element (b) address (c) attribute (d) editor
- 38.📄 What is the first line of an HTML5 page? (a) <head> (b) <body> (c) <!DOCTYPE html> (d) <html>
- 39.📋 Which list tag lists things in any order? (a) <ol> (b) <ul> (c) <li>
- 40.🔢 In a basic web page file, which comes LAST? (a) <body> (b) </html> (c) </head> (d) <html>
Answer key
- <!--
- 6
- <h1>
- Yes
- <h6>
- kite.png
- <li>
- line 1
- numbers
- as one space
- to describe the image
- <body>
- line 1
- Hello, world!
- line 2
- 1
- False
- Birthday cake
- tags
- Cricket is fun.
- <a>
- bus.jpg
- </b>
- <h1>
- True
- True
- <h1>
- False
- 4
- Language
- <h1>
- A happy dog
- line 3
- an opening tag
- Our school trip
- True
- element
- <!DOCTYPE html>
- <ul>
- </html>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids