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 is the closing tag for <h2>? (a) <\h2> (b) <h2> (c) <h2/> (d) </h2>
-
2.🔍 Which line is missing its closing tag?
line 1: <strong>Our school trip</strong>
line 2: <small>Rain today</small>
line 3: <h1>I love mangoes. (a) line 1 (b) line 3 (c) line 2 - 3.🔠 Which heading shows the SMALLEST text: <h1>, <h6>, <h3> or <h5>? (a) <h3> (b) <h6> (c) <h1> (d) <h5>
- 4.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
-
5.🔗 Where does this link open?
<a href="art.html" target="_blank">Visit the site</a> (a) in a new tab (b) in the same tab - 6.Which of these is an opening tag? (a) </title> (b) </h1> (c) </body> (d) <li>
- 7.🔤 In “HTML”, what do the letters HT stand for? (a) Home Text (b) HyperText (c) Hot Tags (d) High Tech
- 8.🖼️ Which attribute of <img> is read by screen readers? (a) height (b) alt (c) width (d) src
- 9.🏷️ Is </p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
10.🔗 Which address opens when you click this link?
<a href="games.html">Art corner</a> (a) Art corner (b) about.html (c) contact.html (d) games.html -
11.📝 How many paragraphs does this code make?
<p>Our school trip</p>
<p>Cricket is fun.</p>
<h2>Fun facts</h2>
<h2>Good morning!</h2>
<p>My best friend</p> - 12.Which of these goes in the body? (a) <style> (b) <title> (c) <link rel="stylesheet"> (d) <h1>
- 13.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h3> or <h4>? (a) <h4> (b) <h1> (c) <h6> (d) <h3>
- 14.📄 What is the first line of an HTML5 page? (a) <!DOCTYPE html> (b) <body> (c) <html> (d) <head>
-
15.🔗 Which address opens when you click this link?
<a href="quiz.html">Take the quiz</a> (a) about.html (b) games.html (c) Take the quiz (d) quiz.html -
16.💬 How many paragraphs show on the page?
<p>Fun facts</p>
<!-- <p>Hello, world!</p> -->
<p>My best friend</p>
<!-- <p>Rain today</p> -->
<p>Our school trip</p> -
17.🔍 Which line is missing its closing tag?
line 1: <p>Fun facts</p>
line 2: <i>Hello, world!
line 3: <u>Our school trip</u> (a) line 1 (b) line 3 (c) line 2 - 18.📝 What does <br> do? (a) adds a picture (b) makes a list (c) starts a new line (d) makes text bold
- 19.🖼️ Which attribute of <img> shows if the image fails? (a) height (b) alt (c) src (d) width
- 20.🏷️ Which is the closing tag for <small>? (a) <small> (b) </small> (c) <\small> (d) <small/>
-
21.🔍 One closing tag is missing. Which one?
<h1>My best friend</h1>
<u>Cricket is fun.</u>
<h3>Hello, world! (a) </b> (b) </u> (c) </h1> (d) </h3> - 22.Which of these is true of a web browser? (a) hosts websites online (b) turns HTML into a page (c) stores a website’s files (d) sends pages over the net
- 23.🏷️ What does a closing tag have that an opening tag does not? (a) a slash / (b) a dollar $ (c) a dot . (d) a hash #
-
24.📋 Does this list show bullets or numbers?
<ol>
<li>Mango</li>
<li>Jamun</li>
</ol> (a) numbers (b) bullets -
25.🔗 Which words do you click on?
<a href="quiz.html">Take the quiz</a> (a) quiz.html (b) Play games (c) href (d) Take the quiz -
26.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="100"> (a) A red kite (b) cake.jpg (c) map.png (d) kite.png -
27.🔍 One closing tag is missing. Which one?
<h1>Rain today</h1>
<h2>My pets</h2>
<h3>My best friend (a) </h3> (b) </u> (c) </h1> (d) </h2> - 28.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h5> or <h2>? (a) <h5> (b) <h6> (c) <h2> (d) <h1>
- 29.Which of these goes in the head? (a) <a> (b) <ul> (c) <title> (d) <p>
- 30.📄 Can HTML on its own count button clicks? (a) No (b) Yes
- 31.🔗 What does target="_blank" do to a link? (a) opens it in a new tab (b) makes it bold (c) hides the link (d) makes it blank
- 32.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <br> (d) <ol>
- 33.🔠 Which heading shows the SMALLEST text: <h4>, <h3>, <h6> or <h5>? (a) <h4> (b) <h5> (c) <h3> (d) <h6>
- 34.True or false: HTML on its own cannot show paragraphs. (a) True (b) False
- 35.Which of these is an empty tag? (a) <b> (b) <li> (c) <img> (d) <title>
-
36.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="bus.jpg" alt="Our school bus" width="300"> (a) An old fort (b) width (c) bus.jpg (d) Our school bus -
37.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<p>Fun facts</p>
<p>Rain today</p>
<!-- <p>My pets</p> -->
<p>Our school trip</p> -
38.🔗 Which words do you click on?
<a href="about.html">Take the quiz</a> (a) href (b) Play games (c) Take the quiz (d) about.html - 39.📄 Where does <h1> go: in the head or in the body? (a) in the body (b) in the head
-
40.💬 How many paragraphs show on the page?
<p>The red kite</p>
<p>Rain today</p>
<!-- <p>Cricket is fun.</p> -->
Answer key
- </h2>
- line 3
- <h6>
- Yes
- in a new tab
- <li>
- HyperText
- alt
- a closing tag
- games.html
- 3
- <h1>
- <h1>
- <!DOCTYPE html>
- quiz.html
- 3
- line 2
- starts a new line
- alt
- </small>
- </h3>
- turns HTML into a page
- a slash /
- numbers
- Take the quiz
- kite.png
- </h3>
- <h1>
- <title>
- No
- opens it in a new tab
- <ul>
- <h6>
- False
- <img>
- Our school bus
- 3
- Take the quiz
- in the body
- 2
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids