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 address opens when you click this link?
<a href="contact.html">About us</a> (a) About us (b) maths.html (c) https://example.com (d) contact.html - 2.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <br> (c) <ol> (d) <ul>
- 3.True or false: a code editor colours code to help us. (a) False (b) True
- 4.True or false: in <img>, alt tells which image to load. (a) True (b) False
- 5.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
- 6.Which of these is true of a web server? (a) has an address bar (b) opens web pages for us (c) sends pages over the net (d) colours code to help us
-
7.💬 Which text will NOT show on the page?
<!-- <p>Fun facts</p> -->
<p>The red kite</p>
<p>My pets</p> (a) The red kite (b) My pets (c) Fun facts - 8.Which of these goes in the head? (a) <table> (b) <style> (c) <p> (d) <img>
- 9.📄 Can HTML on its own show paragraphs? (a) No (b) Yes
- 10.🔢 In a basic web page file, which comes FIRST? (a) </html> (b) <body> (c) <!DOCTYPE html> (d) <html>
-
11.💬 Which text will NOT show on the page?
<p>Cricket is fun.</p>
<p>Hello, world!</p>
<!-- <p>The red kite</p> -->
<p>My best friend</p> (a) My best friend (b) The red kite (c) Hello, world! (d) Cricket is fun. -
12.🔍 One closing tag is missing. Which one?
<strong>My pets
<i>Cricket is fun.</i>
<em>The red kite</em> (a) </i> (b) </b> (c) </em> (d) </strong> - 13.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h6> or <h4>? (a) <h4> (b) <h6> (c) <h2> (d) <h1>
-
14.🔗 Which words do you click on?
<a href="quiz.html">Art corner</a> (a) School news (b) href (c) Art corner (d) quiz.html -
15.💬 Which text will NOT show on the page?
<!-- <p>Rain today</p> -->
<p>My pets</p>
<p>My best friend</p> (a) Rain today (b) My pets (c) My best friend - 16.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h1> or <h4>? (a) <h1> (b) <h3> (c) <h2> (d) <h4>
- 17.🏷️ Is <h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 18.🔗 Which attribute holds the address of a link? (a) id (b) href (c) alt (d) src
- 19.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
-
20.💬 How many paragraphs show on the page?
<p>Cricket is fun.</p>
<!-- <p>I love mangoes.</p> -->
<!-- <p>Fun facts</p> -->
<p>Our school trip</p> - 21.True or false: <ul> is an unordered list. (a) False (b) True
- 22.Which of these is a closing tag? (a) <p> (b) <h1> (c) <li> (d) </title>
-
23.📋 Does this list show bullets or numbers?
<ol>
<li>Mango</li>
<li>Jamun</li>
<li>Litchi</li>
</ol> (a) bullets (b) numbers - 24.True or false: HTML on its own cannot show paragraphs. (a) False (b) True
-
25.🔍 One closing tag is missing. Which one?
<u>My pets
<h2>Rain today</h2>
<h3>Hello, world!</h3> (a) </h2> (b) </u> (c) </h3> (d) </p> -
26.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Rivers flow<br>Kites fly high<br>Stars shine<br>Roses are red</p> - 27.True or false: <input> is an empty tag. (a) True (b) False
-
28.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>Easy snacks</h1>
<p>Mars is red.</p>
</body>
</html> (a) Mars is red. (b) Easy snacks (c) Space Facts (d) body - 29.True or false: <title> is an empty tag. (a) True (b) False
- 30.🔠 How many heading levels does HTML have? (a) 6 (b) 10 (c) 3 (d) 4
-
31.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Art Gallery</title>
</head>
<body>
<h1>My drawings</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) My drawings (b) Art Gallery (c) Thanks for visiting. (d) body -
32.💬 Which text will NOT show on the page?
<!-- <p>My pets</p> -->
<p>Fun facts</p>
<p>My best friend</p> (a) Fun facts (b) My pets (c) My best friend - 33.True or false: <ul> has a closing tag. (a) False (b) True
- 34.🔍 Which is the odd one out? (a) is where we type code (b) shows line numbers (c) saves our .html files (d) hosts websites online
-
35.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="250"> (a) width (b) Map of India (c) kite.png (d) A red kite -
36.🖼️ 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) A happy dog (c) dog.jpg (d) width - 37.🌍 Which program shows a web page to us? (a) a calculator (b) a paint program (c) a music player (d) a web browser
- 38.True or false: a code editor is where we type code. (a) True (b) False
- 39.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
40.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="100"> (a) map.png (b) Map of India (c) width (d) Birthday cake
Answer key
- contact.html
- <ol>
- True
- False
- <ul>
- sends pages over the net
- Fun facts
- <style>
- Yes
- <!DOCTYPE html>
- The red kite
- </strong>
- <h1>
- Art corner
- Rain today
- <h1>
- an opening tag
- href
- Yes
- 2
- True
- </title>
- numbers
- False
- </u>
- 5
- True
- Easy snacks
- False
- 6
- My drawings
- My pets
- True
- hosts websites online
- A red kite
- A happy dog
- a web browser
- True
- has a closing tag
- Map of India
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids