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 of these is a closing tag? (a) <title> (b) </title> (c) <body> (d) <p>
-
2.🖼️ How many pixels wide is the picture drawn?
<img src="tiger.jpg" alt="A tiger asleep" width="200"> - 3.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 4.True or false: <hr> is an empty tag. (a) False (b) True
- 5.🏷️ Which is the closing tag for <h2>? (a) <h2/> (b) <h2> (c) </h2> (d) <\h2>
- 6.🔍 Which is the odd one out? (a) saves our .html files (b) colours code to help us (c) opens web pages for us (d) shows line numbers
- 7.Which of these is true of a web browser? (a) is where we type code (b) shows line numbers (c) sends pages over the net (d) has an address bar
- 8.📝 Does <input> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 9.📝 What does <hr> draw? (a) a picture (b) a link (c) a line across the page (d) a table
- 10.📝 Does <h1> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 11.True or false: <style> goes in the body. (a) True (b) False
-
12.🔍 One closing tag is missing. Which one?
<em>My pets</em>
<h3>Hello, world!</h3>
<small>My best friend (a) </h3> (b) </small> (c) </em> (d) </b> - 13.True or false: a web server answers page requests. (a) True (b) False
- 14.🏷️ Every HTML tag starts with which sign? (a) { (b) < (c) ( (d) [
- 15.🏷️ Which is the closing tag for <small>? (a) <\small> (b) </small> (c) <small/> (d) <small>
-
16.🔗 Where does this link open?
<a href="contact.html" target="_blank">Take the quiz</a> (a) in a new tab (b) in the same tab -
17.📋 How many items does this list show?
<ol>
<li>Orange</li>
<li>Jamun</li>
<li>Mango</li>
<li>Grapes</li>
</ol> - 18.🔍 Which is the odd one out? (a) saves our .html files (b) answers page requests (c) stores a website’s files (d) hosts websites online
-
19.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>My pets</p>
<p>The red kite</p> (a) Our school trip (b) My pets (c) The red kite -
20.🔗 Which words do you click on?
<a href="maths.html">Maths fun</a> (a) maths.html (b) href (c) Art corner (d) Maths fun -
21.📝 On how many lines does the browser show this paragraph?
<p>Kites fly high<br>Roses are red<br>Birds sing<br>Sky is blue<br>Stars shine</p> -
22.🔍 One closing tag is missing. Which one?
<h3>Rain today
<h2>My pets</h2>
<small>Hello, world!</small> (a) </h1> (b) </h2> (c) </small> (d) </h3> -
23.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Kites fly high<br>Rivers flow<br>Birds sing</p> -
24.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="250"> (a) cake.jpg (b) A happy dog (c) Birthday cake (d) width - 25.True or false: in <img>, alt shows if the image fails. (a) False (b) True
- 26.📄 Can HTML on its own make bullet lists? (a) Yes (b) No
- 27.🖼️ Which attribute of <img> is read by screen readers? (a) src (b) width (c) height (d) alt
- 28.🔠 Which heading shows the BIGGEST text: <h6>, <h5>, <h1> or <h2>? (a) <h6> (b) <h5> (c) <h2> (d) <h1>
- 29.True or false: <img> is an empty tag. (a) False (b) True
-
30.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>Match report</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) index.html (b) Cricket Club (c) Thanks for visiting. (d) Match report - 31.🌐 Which one is where we type code? (a) a code editor (b) a web browser (c) a web server
- 32.📝 Does <title> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 33.Which of these has a closing tag? (a) <hr> (b) <meta> (c) <input> (d) <b>
- 34.Which of these is an opening tag? (a) </li> (b) <b> (c) </title> (d) </h1>
-
35.🔗 Which words do you click on?
<a href="https://example.com">Maths fun</a> (a) https://example.com (b) Maths fun (c) Art corner (d) href - 36.🔗 Which tag makes a clickable link? (a) <p> (b) <link> (c) <a> (d) <img>
- 37.📄 Which part holds everything you see on the page? (a) the title (b) the head (c) the body (d) the doctype
- 38.Which of these is true of a code editor? (a) has an address bar (b) shows pages from the web (c) colours code to help us (d) stores a website’s files
- 39.🔗 Which attribute holds the address of a link? (a) src (b) href (c) id (d) alt
- 40.📋 Which list tag is an ordered list? (a) <ul> (b) <li> (c) <ol>
Answer key
- </title>
- 200
- No
- True
- </h2>
- opens web pages for us
- has an address bar
- an empty tag
- a line across the page
- has a closing tag
- False
- </small>
- True
- <
- </small>
- in a new tab
- 4
- saves our .html files
- Our school trip
- Maths fun
- 5
- </h3>
- 4
- Birthday cake
- True
- Yes
- alt
- <h1>
- True
- Cricket Club
- a code editor
- has a closing tag
- <b>
- <b>
- Maths fun
- <a>
- the body
- colours code to help us
- href
- <ol>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids