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.🔠 Are headings shown in bold by default? (a) Yes (b) No
- 2.True or false: <style> goes in the body. (a) False (b) True
- 3.📛 In <a href="x.html">, what is href? (a) an attribute (b) an element name (c) a comment (d) a closing tag
-
4.🔍 Which line is missing its closing tag?
line 1: <strong>Good morning!
line 2: <h1>Our school trip</h1>
line 3: <em>Cricket is fun.</em> (a) line 3 (b) line 1 (c) line 2 - 5.Which of these has a closing tag? (a) <p> (b) <img> (c) <br> (d) <hr>
- 6.🖼️ Which attribute of <img> sets how tall it is? (a) alt (b) width (c) height (d) src
- 7.True or false: <li> has a closing tag. (a) True (b) False
- 8.🔠 Which heading shows the BIGGEST text: <h1>, <h2>, <h3> or <h6>? (a) <h2> (b) <h6> (c) <h1> (d) <h3>
- 9.📋 Which list tag is an ordered list? (a) <ul> (b) <li> (c) <ol>
-
10.📝 How many paragraphs does this code make?
<p>Good morning!</p>
<p>Rain today</p>
<p>Our school trip</p>
<p>Good morning!</p> - 11.🌐 Which one answers page requests? (a) a web browser (b) a code editor (c) a web server
- 12.🔠 Which heading shows the SMALLEST text: <h4>, <h2>, <h1> or <h5>? (a) <h5> (b) <h1> (c) <h4> (d) <h2>
-
13.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Class 7 Blog</title>
</head>
<body>
<h1>My drawings</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) My drawings (b) body (c) Class 7 Blog (d) Thanks for visiting. -
14.🔠 How many headings are in this code?
<h1>My pets</h1>
<h2>I love mangoes.</h2>
<p>I love mangoes.</p>
<p>Our school trip</p>
<h2>Rain today</h2> - 15.True or false: <input> is an empty tag. (a) True (b) False
- 16.True or false: in <img>, src tells which image to load. (a) True (b) False
- 17.📄 Can HTML on its own make bullet lists? (a) Yes (b) No
-
18.📋 What number does the browser show next to “Guava”?
<ol>
<li>Jamun</li>
<li>Papaya</li>
<li>Mango</li>
<li>Guava</li>
</ol> -
19.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Riya’s Recipes</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Mars is red.</p>
</body>
</html> (a) Riya’s Recipes (b) Welcome! (c) Mars is red. (d) index.html - 20.Which of these is a closing tag? (a) <h1> (b) <b> (c) </b> (d) <li>
-
21.🔠 How many headings are in this code?
<h1>Our school trip</h1>
<p>The red kite</p>
<h4>Fun facts</h4> -
22.📋 How many items does this list show?
<ol>
<li>Orange</li>
<li>Litchi</li>
<li>Mango</li>
<li>Banana</li>
<li>Guava</li>
<li>Grapes</li>
</ol> - 23.💬 How does an HTML comment end? (a) // (b) --> (c) >> (d) */
- 24.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h3> or <h6>? (a) <h3> (b) <h2> (c) <h6> (d) <h1>
- 25.Which of these goes in the body? (a) <meta charset="utf-8"> (b) <title> (c) <h1> (d) <link rel="stylesheet">
- 26.🔠 How many heading levels does HTML have? (a) 3 (b) 4 (c) 6 (d) 10
- 27.🔗 What does target="_blank" do to a link? (a) makes it bold (b) makes it blank (c) opens it in a new tab (d) hides the link
- 28.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h6> or <h4>? (a) <h4> (b) <h5> (c) <h6> (d) <h1>
- 29.🏷️ Every HTML tag starts with which sign? (a) [ (b) < (c) { (d) (
- 30.🏷️ Which is the closing tag for <i>? (a) <i/> (b) </i> (c) <i> (d) <\i>
- 31.📋 Which list tag goes inside ul or ol? (a) <ol> (b) <li> (c) <ul>
- 32.📝 Does <p> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 33.Which of these goes in the head? (a) <ul> (b) <a> (c) <style> (d) <p>
-
34.📋 Does this list show bullets or numbers?
<ol>
<li>Grapes</li>
<li>Jamun</li>
<li>Banana</li>
</ol> (a) numbers (b) bullets - 35.True or false: HTML on its own can make a form. (a) True (b) False
- 36.📋 Which list shows the steps of a recipe best? (a) <ol> (b) <hr> (c) <br> (d) <ul>
- 37.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h6> or <h5>? (a) <h5> (b) <h2> (c) <h6> (d) <h3>
-
38.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="350"> (a) map.png (b) Map of India (c) width (d) Birthday cake -
39.📝 On how many lines does the browser show this paragraph?
<p>Roses are red<br>Rivers flow</p> - 40.📄 Where does the text of <title> appear? (a) nowhere (b) at the bottom (c) in a big heading (d) on the browser tab
Answer key
- Yes
- False
- an attribute
- line 1
- <p>
- height
- True
- <h1>
- <ol>
- 4
- a web server
- <h5>
- My drawings
- 3
- True
- True
- Yes
- 4
- Riya’s Recipes
- </b>
- 2
- 6
- -->
- <h1>
- <h1>
- 6
- opens it in a new tab
- <h1>
- <
- </i>
- <li>
- has a closing tag
- <style>
- numbers
- True
- <ol>
- <h2>
- Map of India
- 2
- on the browser tab
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids