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 list tag is an ordered list? (a) <li> (b) <ol> (c) <ul>
- 2.True or false: a code editor stores a website’s files. (a) False (b) True
-
3.🖼️ Which picture file does the browser load?
<img src="cake.jpg" alt="Birthday cake" width="300"> (a) Birthday cake (b) moon.png (c) cake.jpg (d) dog.jpg - 4.Which of these is an opening tag? (a) </body> (b) </p> (c) </b> (d) <h1>
- 5.🏷️ Every HTML tag starts with which sign? (a) [ (b) { (c) < (d) (
-
6.🔗 Which words do you click on?
<a href="quiz.html">About us</a> (a) About us (b) Contact us (c) href (d) quiz.html -
7.🔗 Which address opens when you click this link?
<a href="about.html">Art corner</a> (a) Art corner (b) contact.html (c) https://example.com (d) about.html - 8.📋 Which list tag shows bullet points? (a) <li> (b) <ul> (c) <ol>
-
9.🖼️ How many pixels wide is the picture drawn?
<img src="dog.jpg" alt="A happy dog" width="300"> - 10.🔤 In “HTML”, what does the M stand for? (a) Mouse (b) Markup (c) Modern (d) Machine
- 11.🏷️ Which is the closing tag for <p>? (a) <p/> (b) </p> (c) <\p> (d) <p>
- 12.📝 Does <img> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
13.🔠 How many headings are in this code?
<h1>Hello, world!</h1>
<p>Good morning!</p>
<h2>I love mangoes.</h2>
<h4>Good morning!</h4> -
14.🔍 One closing tag is missing. Which one?
<h3>Hello, world!
<strong>My pets</strong>
<b>Fun facts</b> (a) </b> (b) </strong> (c) </h3> (d) </h1> -
15.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>My drawings</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) My drawings (b) Space Facts (c) body (d) Thanks for visiting. - 16.🔤 In “HTML”, what does the L stand for? (a) Line (b) Laptop (c) Link (d) Language
-
17.📋 What number does the browser show next to “Mango”?
<ol start="9">
<li>Jamun</li>
<li>Guava</li>
<li>Mango</li>
<li>Banana</li>
<li>Grapes</li>
<li>Papaya</li>
</ol> -
18.💬 Which text will NOT show on the page?
<p>Fun facts</p>
<!-- <p>My pets</p> -->
<p>My best friend</p> (a) My best friend (b) My pets (c) Fun facts -
19.📋 How many items does this list show?
<ol>
<li>Orange</li>
<li>Mango</li>
</ol> - 20.🔗 Which tag makes a clickable link? (a) <p> (b) <img> (c) <link> (d) <a>
-
21.🔗 Which address opens when you click this link?
<a href="https://example.com">Contact us</a> (a) maths.html (b) https://example.com (c) Contact us (d) art.html - 22.🏷️ Is </p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
23.📋 What number does the browser show next to “Banana”?
<ol>
<li>Guava</li>
<li>Orange</li>
<li>Litchi</li>
<li>Papaya</li>
<li>Banana</li>
<li>Jamun</li>
</ol> -
24.🔗 Which address opens when you click this link?
<a href="maths.html">Art corner</a> (a) news.html (b) art.html (c) maths.html (d) Art corner -
25.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="250"> (a) A tiger asleep (b) width (c) fort.jpg (d) An old fort -
26.🖼️ Which picture file does the browser load?
<img src="tiger.jpg" alt="A tiger asleep" width="50"> (a) A tiger asleep (b) kite.png (c) tiger.jpg (d) map.png - 27.📝 Does <ul> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 28.🖼️ Does <img> need a closing tag? (a) Yes (b) No
-
29.💬 How many paragraphs show on the page?
<!-- <p>My pets</p> -->
<p>Our school trip</p>
<!-- <p>Hello, world!</p> --> -
30.🔍 Which line is missing its closing tag?
line 1: <strong>I love mangoes.</strong>
line 2: <b>Cricket is fun.
line 3: <p>Good morning!</p> (a) line 2 (b) line 1 (c) line 3 - 31.True or false: <h1> is an empty tag. (a) True (b) False
- 32.🧱 HTML gives a web page its ___. (a) sound (b) structure (c) speed (d) colours
- 33.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as one space (c) as a new line (d) as 5 spaces
-
34.📝 How many paragraphs does this code make?
<p>Hello, world!</p>
<h2>My best friend</h2>
<h2>Fun facts</h2>
<p>My pets</p> - 35.🏷️ Is <li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 36.📝 What do we need to write HTML? (a) a printer (b) a plain text editor (c) a paintbrush (d) a microphone
-
37.💬 How many paragraphs show on the page?
<p>My best friend</p>
<p>Cricket is fun.</p>
<!-- <p>The red kite</p> --> -
38.🔗 Where does this link open?
<a href="https://example.com">Play games</a> (a) in a new tab (b) in the same tab -
39.🔗 Which words do you click on?
<a href="games.html">About us</a> (a) Contact us (b) href (c) games.html (d) About us -
40.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>Easy snacks</h1>
<p>Here is my best one.</p>
</body>
</html> (a) body (b) Here is my best one. (c) Easy snacks (d) Cricket Club
Answer key
- <ol>
- False
- cake.jpg
- <h1>
- <
- About us
- about.html
- <ul>
- 300
- Markup
- </p>
- an empty tag
- 3
- </h3>
- My drawings
- Language
- 11
- My pets
- 2
- <a>
- https://example.com
- a closing tag
- 5
- maths.html
- An old fort
- tiger.jpg
- has a closing tag
- No
- 1
- line 2
- False
- structure
- as one space
- 2
- an opening tag
- a plain text editor
- 2
- in the same tab
- About us
- Easy snacks
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids