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: <h6>, <h1>, <h5> or <h2>? (a) <h5> (b) <h6> (c) <h1> (d) <h2>
-
2.💬 Which text will NOT show on the page?
<p>Hello, world!</p>
<p>Good morning!</p>
<!-- <p>My pets</p> --> (a) Hello, world! (b) Good morning! (c) My pets - 3.🔢 In a basic web page file, which comes FIRST? (a) </body> (b) <!DOCTYPE html> (c) <head> (d) <html>
- 4.🔠 Which heading shows the BIGGEST text: <h3>, <h5>, <h2> or <h1>? (a) <h3> (b) <h2> (c) <h1> (d) <h5>
- 5.Which of these is true of a web browser? (a) colours code to help us (b) opens web pages for us (c) is where we type code (d) shows line numbers
- 6.True or false: <link rel="stylesheet"> goes in the body. (a) False (b) True
- 7.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body
-
8.📋 Does this list show bullets or numbers?
<ol>
<li>Litchi</li>
<li>Guava</li>
<li>Mango</li>
</ol> (a) bullets (b) numbers - 9.True or false: in <img>, height sets how tall it is. (a) False (b) True
-
10.💬 How many paragraphs show on the page?
<p>Cricket is fun.</p>
<!-- <p>Rain today</p> -->
<!-- <p>Fun facts</p> --> -
11.📋 Does this list show bullets or numbers?
<ol>
<li>Litchi</li>
<li>Papaya</li>
<li>Orange</li>
</ol> (a) bullets (b) numbers -
12.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<p>Fun facts</p>
<h3>Hello, world!</h3>
<h2>Cricket is fun.</h2> -
13.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Riya’s Recipes</title>
</head>
<body>
<h1>Match report</h1>
<p>Here is my best one.</p>
</body>
</html> (a) Here is my best one. (b) index.html (c) Match report (d) Riya’s Recipes -
14.📋 Does this list show bullets or numbers?
<ul>
<li>Jamun</li>
<li>Orange</li>
</ul> (a) bullets (b) numbers - 15.True or false: <b> has a closing tag. (a) False (b) True
- 16.📝 Does <br> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 17.📄 Can HTML on its own make bullet lists? (a) Yes (b) No
-
18.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Good morning!</h2>
<h2>Hello, world!</h2> -
19.🔗 Which address opens when you click this link?
<a href="art.html">Art corner</a> (a) news.html (b) quiz.html (c) Art corner (d) art.html -
20.📋 Does this list show bullets or numbers?
<ul>
<li>Banana</li>
<li>Papaya</li>
<li>Grapes</li>
</ul> (a) bullets (b) numbers -
21.🔗 Where does this link open?
<a href="about.html">Contact us</a> (a) in a new tab (b) in the same tab - 22.Which of these is true of a web server? (a) has an address bar (b) shows pages from the web (c) sends pages over the net (d) opens web pages for us
- 23.🖼️ Which attribute of <img> shows if the image fails? (a) src (b) height (c) alt (d) width
-
24.💬 How many paragraphs show on the page?
<!-- <p>Rain today</p> -->
<p>Hello, world!</p>
<p>I love mangoes.</p>
<p>Our school trip</p>
<p>My pets</p> - 25.💬 Why do coders write comments? (a) to add colour (b) to leave notes (c) to show pictures (d) to make links
- 26.🧩 An opening tag + content + a closing tag together make an ___. (a) attribute (b) editor (c) address (d) element
- 27.True or false: in <img>, src names the picture file. (a) True (b) False
- 28.🔠 Are headings shown in bold by default? (a) No (b) Yes
- 29.🔠 Which heading shows the BIGGEST text: <h5>, <h1>, <h2> or <h4>? (a) <h5> (b) <h2> (c) <h1> (d) <h4>
-
30.🔗 Which words do you click on?
<a href="art.html">Play games</a> (a) href (b) About us (c) art.html (d) Play games -
31.🔍 Which line is missing its closing tag?
line 1: <h1>Cricket is fun.
line 2: <b>My pets</b>
line 3: <h3>Good morning!</h3> (a) line 1 (b) line 3 (c) line 2 -
32.🔗 Where does this link open?
<a href="news.html" target="_blank">Take the quiz</a> (a) in a new tab (b) in the same tab - 33.Which of these is an empty tag? (a) <h1> (b) <input> (c) <b> (d) <title>
- 34.Which of these is an opening tag? (a) </b> (b) <title> (c) </title> (d) </h1>
- 35.True or false: <p> has a closing tag. (a) False (b) True
-
36.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Fun facts</h2>
<p>Fun facts</p>
<h2>Fun facts</h2>
<p>Our school trip</p> - 37.📛 In <a href="x.html">, what is href? (a) an element name (b) a comment (c) a closing tag (d) an attribute
- 38.🔗 What does target="_blank" do to a link? (a) hides the link (b) opens it in a new tab (c) makes it blank (d) makes it bold
-
39.📝 How many paragraphs does this code make?
<p>The red kite</p>
<p>My best friend</p>
<h2>Good morning!</h2>
<p>My pets</p> - 40.📝 Does <meta> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
Answer key
- <h1>
- My pets
- <!DOCTYPE html>
- <h1>
- opens web pages for us
- False
- in the body
- numbers
- True
- 1
- numbers
- 3
- Riya’s Recipes
- bullets
- True
- an empty tag
- Yes
- 1
- art.html
- bullets
- in the same tab
- sends pages over the net
- alt
- 4
- to leave notes
- element
- True
- Yes
- <h1>
- Play games
- line 1
- in a new tab
- <input>
- <title>
- True
- 3
- an attribute
- opens it in a new tab
- 3
- an empty tag
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids