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 heading shows the BIGGEST text: <h2>, <h5>, <h3> or <h6>? (a) <h2> (b) <h5> (c) <h3> (d) <h6>
-
2.🔗 Which address opens when you click this link?
<a href="contact.html">Maths fun</a> (a) Maths fun (b) https://example.com (c) maths.html (d) contact.html - 3.🌐 Which one is where we type code? (a) a web browser (b) a web server (c) a code editor
- 4.🏷️ Every HTML tag starts with which sign? (a) ( (b) [ (c) { (d) <
- 5.True or false: <ul> is one item of a list. (a) False (b) True
-
6.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Rivers flow<br>Sky is blue</p> - 7.🏷️ HTML marks up text using ___. (a) keys (b) wires (c) pixels (d) tags
- 8.Which of these is an empty tag? (a) <ul> (b) <title> (c) <b> (d) <img>
-
9.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Riya’s Recipes</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) Riya’s Recipes (b) index.html (c) Welcome! (d) Thanks for visiting. - 10.🔠 Which heading shows the SMALLEST text: <h1>, <h4>, <h5> or <h2>? (a) <h1> (b) <h2> (c) <h5> (d) <h4>
- 11.🖼️ Which attribute of <img> is read by screen readers? (a) width (b) alt (c) src (d) height
- 12.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h2> or <h5>? (a) <h4> (b) <h5> (c) <h2> (d) <h1>
- 13.Which of these goes in the head? (a) <p> (b) <table> (c) <h1> (d) <style>
-
14.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<p>Hello, world!</p>
<p>Fun facts</p>
<!-- <p>I love mangoes.</p> -->
<p>My best friend</p> - 15.🖼️ Does <img> need a closing tag? (a) No (b) Yes
-
16.💬 Which text will NOT show on the page?
<!-- <p>Hello, world!</p> -->
<p>The red kite</p>
<p>Rain today</p> (a) Rain today (b) The red kite (c) Hello, world! -
17.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>My Hobbies</title>
</head>
<body>
<h1>Planets</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) body (b) Thanks for visiting. (c) Planets (d) My Hobbies - 18.📝 What does <hr> draw? (a) a table (b) a link (c) a picture (d) a line across the page
-
19.💬 How many paragraphs show on the page?
<!-- <p>Fun facts</p> -->
<!-- <p>Cricket is fun.</p> -->
<!-- <p>My best friend</p> -->
<p>Good morning!</p>
<!-- <p>The red kite</p> --> -
20.💬 How many paragraphs show on the page?
<p>Hello, world!</p>
<p>I love mangoes.</p>
<p>Rain today</p>
<!-- <p>Cricket is fun.</p> --> - 21.📋 Which list tag goes inside ul or ol? (a) <li> (b) <ul> (c) <ol>
- 22.🌐 Which one shows line numbers? (a) a web server (b) a web browser (c) a code editor
- 23.🔠 Which heading shows the SMALLEST text: <h5>, <h1>, <h3> or <h6>? (a) <h3> (b) <h6> (c) <h5> (d) <h1>
- 24.🌐 Which one saves our .html files? (a) a web server (b) a code editor (c) a web browser
- 25.📄 Where does <title> go: in the head or in the body? (a) in the head (b) in the body
-
26.📋 How many items does this list show?
<ul>
<li>Mango</li>
<li>Banana</li>
<li>Orange</li>
<li>Guava</li>
<li>Papaya</li>
<li>Jamun</li>
</ul> -
27.🔗 Which words do you click on?
<a href="https://example.com">Maths fun</a> (a) Maths fun (b) href (c) https://example.com (d) Art corner -
28.🖼️ Which picture file does the browser load?
<img src="fort.jpg" alt="An old fort" width="50"> (a) An old fort (b) kite.png (c) fort.jpg (d) tiger.jpg - 29.🔠 Are headings shown in bold by default? (a) Yes (b) No
-
30.🔍 One closing tag is missing. Which one?
<i>Fun facts</i>
<b>Rain today</b>
<h3>My pets (a) </h1> (b) </i> (c) </b> (d) </h3> -
31.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<p>Hello, world!</p>
<p>My best friend</p>
<!-- <p>Fun facts</p> --> - 32.🔠 Which heading shows the SMALLEST text: <h4>, <h1>, <h2> or <h3>? (a) <h2> (b) <h1> (c) <h4> (d) <h3>
-
33.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="150"> (a) Map of India (b) Birthday cake (c) map.png (d) width -
34.🖼️ Which picture file does the browser load?
<img src="cake.jpg" alt="Birthday cake" width="250"> (a) Birthday cake (b) cake.jpg (c) moon.png (d) dog.jpg - 35.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ol> (c) <br> (d) <ul>
-
36.📋 What number does the browser show next to “Orange”?
<ol>
<li>Litchi</li>
<li>Mango</li>
<li>Orange</li>
<li>Grapes</li>
<li>Guava</li>
<li>Banana</li>
</ol> - 37.🔠 How many <h1> headings should a page usually have? (a) 1 (b) 3 (c) 6 (d) 10
- 38.📄 Where does <meta charset="utf-8"> go: in the head or in the body? (a) in the body (b) in the head
- 39.📄 Can HTML on its own make a form? (a) Yes (b) No
-
40.📝 How many paragraphs does this code make?
<p>Cricket is fun.</p>
<h2>My best friend</h2>
<h2>Hello, world!</h2>
<h2>My pets</h2>
<h2>My best friend</h2>
<h2>Fun facts</h2>
Answer key
- <h2>
- contact.html
- a code editor
- <
- False
- 3
- tags
- <img>
- Riya’s Recipes
- <h5>
- alt
- <h1>
- <style>
- 4
- No
- Hello, world!
- Planets
- a line across the page
- 1
- 3
- <li>
- a code editor
- <h6>
- a code editor
- in the head
- 6
- Maths fun
- fort.jpg
- Yes
- </h3>
- 2
- <h4>
- Map of India
- cake.jpg
- <ul>
- 3
- 1
- in the head
- Yes
- 1
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids