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: <h4>, <h3>, <h5> or <h6>? (a) <h5> (b) <h6> (c) <h3> (d) <h4>
- 2.🔠 Which heading shows the BIGGEST text: <h2>, <h5>, <h4> or <h1>? (a) <h5> (b) <h4> (c) <h2> (d) <h1>
- 3.🏷️ HTML marks up text using ___. (a) keys (b) wires (c) tags (d) pixels
- 4.💬 How does an HTML comment start? (a) <!-- (b) # (c) /* (d) //
- 5.Which of these is a closing tag? (a) <h1> (b) <p> (c) <title> (d) </li>
- 6.True or false: <li> lists things in any order. (a) True (b) False
- 7.🏷️ What does a closing tag have that an opening tag does not? (a) a dollar $ (b) a dot . (c) a slash / (d) a hash #
-
8.🔍 Which line is missing its closing tag?
line 1: <h2>Rain today</h2>
line 2: <u>I love mangoes.
line 3: <i>Fun facts</i> (a) line 1 (b) line 3 (c) line 2 - 9.📋 Which list tag is an ordered list? (a) <li> (b) <ul> (c) <ol>
- 10.🔗 Which tag makes a clickable link? (a) <a> (b) <img> (c) <p> (d) <link>
-
11.💬 Which text will NOT show on the page?
<p>Hello, world!</p>
<!-- <p>Cricket is fun.</p> -->
<p>My pets</p> (a) Cricket is fun. (b) My pets (c) Hello, world! -
12.🔍 Which line is missing its closing tag?
line 1: <small>Our school trip
line 2: <b>My best friend</b>
line 3: <strong>Fun facts</strong> (a) line 3 (b) line 1 (c) line 2 - 13.🔗 Which attribute holds the address of a link? (a) id (b) href (c) src (d) alt
- 14.Which of these goes in the body? (a) <title> (b) <style> (c) <p> (d) <link rel="stylesheet">
- 15.🔤 In “HTML”, what do the letters HT stand for? (a) Home Text (b) High Tech (c) Hot Tags (d) HyperText
-
16.💬 How many paragraphs show on the page?
<p>Fun facts</p>
<!-- <p>I love mangoes.</p> -->
<!-- <p>Rain today</p> --> -
17.📋 How many items does this list show?
<ul>
<li>Litchi</li>
<li>Jamun</li>
<li>Mango</li>
</ul> -
18.💬 Which text will NOT show on the page?
<p>My best friend</p>
<!-- <p>Hello, world!</p> -->
<p>Fun facts</p>
<p>Cricket is fun.</p> (a) Hello, world! (b) My best friend (c) Fun facts (d) Cricket is fun. - 19.📋 Which list tag lists things in any order? (a) <ol> (b) <ul> (c) <li>
-
20.🔍 Which line is missing its closing tag?
line 1: <u>Rain today
line 2: <h2>Hello, world!</h2>
line 3: <h1>My best friend</h1> (a) line 3 (b) line 2 (c) line 1 -
21.🖼️ How many pixels wide is the picture drawn?
<img src="map.png" alt="Map of India" width="100"> - 22.🔗 What does HyperText mean? (a) text in colour (b) secret text (c) text with links (d) very big text
- 23.🌐 Which one sends pages over the net? (a) a web server (b) a code editor (c) a web browser
-
24.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="dog.jpg" alt="A happy dog" width="50"> (a) A happy dog (b) width (c) The full moon (d) dog.jpg -
25.🔗 Which words do you click on?
<a href="about.html">Art corner</a> (a) School news (b) Art corner (c) href (d) about.html -
26.💬 How many paragraphs show on the page?
<!-- <p>My pets</p> -->
<!-- <p>My best friend</p> -->
<p>Hello, world!</p> -
27.🔠 How many headings are in this code?
<h1>Our school trip</h1>
<p>My pets</p>
<h3>Rain today</h3> - 28.True or false: <li> shows bullet points. (a) False (b) True
- 29.Which of these has a closing tag? (a) <hr> (b) <input> (c) <ul> (d) <meta>
-
30.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>Hello, world!</p>
<!-- <p>The red kite</p> --> - 31.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
- 32.🖼️ Which attribute of <img> names the picture file? (a) width (b) alt (c) height (d) src
-
33.📋 Does this list show bullets or numbers?
<ul>
<li>Orange</li>
<li>Jamun</li>
<li>Banana</li>
</ul> (a) numbers (b) bullets -
34.🔍 One closing tag is missing. Which one?
<b>My pets</b>
<h3>Cricket is fun.
<u>Fun facts</u> (a) </b> (b) </u> (c) </h2> (d) </h3> - 35.🔍 Which is the odd one out? (a) stores a website’s files (b) is where we type code (c) sends pages over the net (d) answers page requests
-
36.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>Fun facts</p>
<p>Cricket is fun.</p>
<p>Good morning!</p>
<p>Hello, world!</p> -
37.🔗 Which words do you click on?
<a href="games.html">About us</a> (a) Contact us (b) games.html (c) About us (d) href -
38.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="400"> (a) Birthday cake (b) width (c) cake.jpg (d) A happy dog -
39.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Kites fly high<br>Sky is blue<br>Stars shine</p> - 40.💬 Why do coders write comments? (a) to show pictures (b) to add colour (c) to make links (d) to leave notes
Answer key
- <h3>
- <h1>
- tags
- <!--
- </li>
- False
- a slash /
- line 2
- <ol>
- <a>
- Cricket is fun.
- line 1
- href
- <p>
- HyperText
- 1
- 3
- Hello, world!
- <ul>
- line 1
- 100
- text with links
- a web server
- A happy dog
- Art corner
- 1
- 2
- False
- <ul>
- 1
- Yes
- src
- bullets
- </h3>
- is where we type code
- 4
- About us
- Birthday cake
- 4
- to leave notes
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids