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.📝 Does <p> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
2.🔗 Where does this link open?
<a href="quiz.html" target="_blank">School news</a> (a) in the same tab (b) in a new tab -
3.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>My best friend</p>
<!-- <p>The red kite</p> --> - 4.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h3> or <h5>? (a) <h1> (b) <h5> (c) <h3> (d) <h6>
- 5.📄 Where does <link rel="stylesheet"> go: in the head or in the body? (a) in the head (b) in the body
-
6.🔗 Where does this link open?
<a href="about.html" target="_blank">School news</a> (a) in a new tab (b) in the same tab -
7.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="400"> - 8.Which of these is an opening tag? (a) </p> (b) </h1> (c) </title> (d) <h1>
-
9.📋 What number does the browser show next to “Orange”?
<ol start="8">
<li>Jamun</li>
<li>Orange</li>
<li>Grapes</li>
</ol> -
10.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Stars shine<br>Sky is blue<br>Kites fly high</p> -
11.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="250"> - 12.🔠 How many heading levels does HTML have? (a) 6 (b) 4 (c) 3 (d) 10
- 13.🔠 Which heading shows the BIGGEST text: <h3>, <h6>, <h1> or <h2>? (a) <h3> (b) <h6> (c) <h1> (d) <h2>
-
14.📋 What number does the browser show next to “Guava”?
<ol>
<li>Mango</li>
<li>Banana</li>
<li>Papaya</li>
<li>Litchi</li>
<li>Jamun</li>
<li>Guava</li>
</ol> - 15.🌐 Which one shows line numbers? (a) a code editor (b) a web server (c) a web browser
- 16.🔡 Are HTML tag names usually written in small letters? (a) Yes (b) No
-
17.🔗 Where does this link open?
<a href="about.html" target="_blank">About us</a> (a) in the same tab (b) in a new tab - 18.🔠 Which heading shows the SMALLEST text: <h2>, <h6>, <h3> or <h5>? (a) <h6> (b) <h2> (c) <h5> (d) <h3>
- 19.True or false: in <img>, height is read by screen readers. (a) False (b) True
-
20.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>The red kite</p>
<!-- <p>Good morning!</p> -->
<!-- <p>I love mangoes.</p> --> -
21.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="50"> (a) Birthday cake (b) width (c) map.png (d) Map of India -
22.📋 Does this list show bullets or numbers?
<ul>
<li>Litchi</li>
<li>Papaya</li>
</ul> (a) numbers (b) bullets -
23.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="50"> (a) cake.jpg (b) kite.png (c) A red kite (d) map.png - 24.📝 What do we need to write HTML? (a) a microphone (b) a printer (c) a plain text editor (d) a paintbrush
- 25.📋 Which list tag lists steps in order? (a) <ul> (b) <li> (c) <ol>
-
26.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Riya’s Recipes</title>
</head>
<body>
<h1>All about me</h1>
<p>I like to read.</p>
</body>
</html> (a) Riya’s Recipes (b) body (c) All about me (d) I like to read. -
27.🔗 Where does this link open?
<a href="about.html" target="_blank">Visit the site</a> (a) in a new tab (b) in the same tab -
28.🔗 Which words do you click on?
<a href="art.html">About us</a> (a) About us (b) art.html (c) href (d) Contact us - 29.🏷️ Which is the closing tag for <h1>? (a) <h1/> (b) <h1> (c) </h1> (d) <\h1>
- 30.Which of these is true of a web server? (a) stores a website’s files (b) shows pages from the web (c) is where we type code (d) shows line numbers
-
31.🔗 Which words do you click on?
<a href="maths.html">About us</a> (a) href (b) maths.html (c) Contact us (d) About us - 32.🏷️ HTML marks up text using ___. (a) wires (b) keys (c) pixels (d) tags
-
33.📋 What number does the browser show next to “Grapes”?
<ol start="5">
<li>Guava</li>
<li>Papaya</li>
<li>Orange</li>
<li>Litchi</li>
<li>Banana</li>
<li>Grapes</li>
</ol> -
34.💬 How many paragraphs show on the page?
<p>Hello, world!</p>
<!-- <p>I love mangoes.</p> -->
<p>My pets</p>
<!-- <p>Cricket is fun.</p> --> - 35.True or false: <ul> shows 1, 2, 3 numbers. (a) False (b) True
- 36.True or false: a web server colours code to help us. (a) False (b) True
-
37.📝 How many paragraphs does this code make?
<p>Our school trip</p>
<h2>The red kite</h2>
<h2>Good morning!</h2>
<h2>My pets</h2> -
38.🔗 Which words do you click on?
<a href="https://example.com">Play games</a> (a) https://example.com (b) Play games (c) href (d) About us - 39.Which of these is a closing tag? (a) </li> (b) <title> (c) <b> (d) <h1>
-
40.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="150">
Answer key
- has a closing tag
- in a new tab
- 1
- <h6>
- in the head
- in a new tab
- 400
- <h1>
- 9
- 4
- 250
- 6
- <h1>
- 6
- a code editor
- Yes
- in a new tab
- <h6>
- False
- 1
- Map of India
- bullets
- kite.png
- a plain text editor
- <ol>
- All about me
- in a new tab
- About us
- </h1>
- stores a website’s files
- About us
- tags
- 10
- 2
- False
- False
- 1
- Play games
- </li>
- 150
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids