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 has a closing tag? (a) <meta> (b) <img> (c) <h1> (d) <br>
- 2.📛 In <a href="x.html">, what is href? (a) an element name (b) an attribute (c) a closing tag (d) a comment
- 3.Which of these is a closing tag? (a) <b> (b) <h1> (c) <p> (d) </li>
- 4.🔤 In “HTML”, what does the L stand for? (a) Line (b) Laptop (c) Link (d) Language
-
5.💬 How many paragraphs show on the page?
<p>My pets</p>
<p>My best friend</p>
<!-- <p>Hello, world!</p> --> -
6.📋 Does this list show bullets or numbers?
<ul>
<li>Banana</li>
<li>Orange</li>
</ul> (a) bullets (b) numbers - 7.📄 Where does the text of <title> appear? (a) in a big heading (b) on the browser tab (c) nowhere (d) at the bottom
- 8.Which of these is true of a code editor? (a) answers page requests (b) sends pages over the net (c) is where we type code (d) shows pages from the web
- 9.📋 Which tag goes around each item of a list? (a) <ul> (b) <ol> (c) <li> (d) <p>
- 10.Which of these is true of a web server? (a) is where we type code (b) opens web pages for us (c) sends pages over the net (d) colours code to help us
-
11.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="bus.jpg" alt="Our school bus" width="400"> (a) Our school bus (b) An old fort (c) bus.jpg (d) width -
12.🖼️ Which picture file does the browser load?
<img src="map.png" alt="Map of India" width="50"> (a) Map of India (b) map.png (c) dog.jpg (d) cake.jpg - 13.📋 Which list suits a shopping list in any order? (a) <ol> (b) <br> (c) <hr> (d) <ul>
-
14.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Art Gallery</title>
</head>
<body>
<h1>Planets</h1>
<p>Here is my best one.</p>
</body>
</html> (a) Art Gallery (b) Planets (c) index.html (d) Here is my best one. - 15.True or false: <p> is an empty tag. (a) True (b) False
- 16.True or false: <p> goes in the head. (a) True (b) False
-
17.🔍 One closing tag is missing. Which one?
<small>Rain today</small>
<h2>My best friend
<h1>Fun facts</h1> (a) </h2> (b) </b> (c) </h1> (d) </small> -
18.💬 Which text will NOT show on the page?
<!-- <p>Cricket is fun.</p> -->
<p>Hello, world!</p>
<p>Rain today</p>
<p>Our school trip</p> (a) Hello, world! (b) Rain today (c) Cricket is fun. (d) Our school trip -
19.🔗 Which words do you click on?
<a href="about.html">Play games</a> (a) href (b) About us (c) Play games (d) about.html - 20.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
- 21.Which of these is an opening tag? (a) </p> (b) </title> (c) </li> (d) <body>
-
22.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>Welcome!</h1>
<p>I like to read.</p>
</body>
</html> (a) Welcome! (b) I like to read. (c) index.html (d) Space Facts -
23.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Stars shine</p> - 24.True or false: HTML on its own cannot make links to pages. (a) True (b) False
- 25.🔍 Which is the odd one out? (a) stores a website’s files (b) opens web pages for us (c) answers page requests (d) hosts websites online
-
26.🖼️ Which picture file does the browser load?
<img src="map.png" alt="Map of India" width="350"> (a) cake.jpg (b) map.png (c) Map of India (d) dog.jpg -
27.🔗 Which address opens when you click this link?
<a href="https://example.com">Take the quiz</a> (a) art.html (b) Take the quiz (c) maths.html (d) https://example.com - 28.🌐 Which one shows line numbers? (a) a web browser (b) a code editor (c) a web server
- 29.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 30.🏷️ Every HTML tag starts with which sign? (a) [ (b) { (c) < (d) (
- 31.Which of these has a closing tag? (a) <meta> (b) <title> (c) <br> (d) <hr>
-
32.🔍 One closing tag is missing. Which one?
<h1>Hello, world!
<b>Fun facts</b>
<h2>I love mangoes.</h2> (a) </h1> (b) </b> (c) </p> (d) </h2> - 33.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 34.🏷️ Is <p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
35.🔗 Which address opens when you click this link?
<a href="games.html">Art corner</a> (a) Art corner (b) games.html (c) about.html (d) contact.html -
36.💬 Which text will NOT show on the page?
<p>My best friend</p>
<!-- <p>My pets</p> -->
<p>Our school trip</p> (a) Our school trip (b) My best friend (c) My pets -
37.💬 Which text will NOT show on the page?
<!-- <p>The red kite</p> -->
<p>Good morning!</p>
<p>Our school trip</p> (a) Good morning! (b) Our school trip (c) The red kite - 38.📄 Which part holds everything you see on the page? (a) the body (b) the head (c) the title (d) the doctype
- 39.🔢 In a basic web page file, which comes first: “<html>” or “<!DOCTYPE html>”? (a) <!DOCTYPE html> (b) <html>
-
40.🔍 One closing tag is missing. Which one?
<small>Our school trip</small>
<b>Cricket is fun.</b>
<strong>My best friend (a) </b> (b) </small> (c) </strong> (d) </em>
Answer key
- <h1>
- an attribute
- </li>
- Language
- 2
- bullets
- on the browser tab
- is where we type code
- <li>
- sends pages over the net
- Our school bus
- map.png
- <ul>
- Art Gallery
- False
- False
- </h2>
- Cricket is fun.
- Play games
- Yes
- <body>
- Space Facts
- 2
- False
- opens web pages for us
- map.png
- https://example.com
- a code editor
- a closing tag
- <
- <title>
- </h1>
- has a closing tag
- an opening tag
- games.html
- My pets
- The red kite
- the body
- <!DOCTYPE html>
- </strong>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids