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 address opens when you click this link?
<a href="games.html">About us</a> (a) about.html (b) About us (c) games.html (d) contact.html - 2.Which of these has a closing tag? (a) <img> (b) <br> (c) <ul> (d) <hr>
-
3.🔍 One closing tag is missing. Which one?
<h3>Fun facts
<p>Our school trip</p>
<u>I love mangoes.</u> (a) </h3> (b) </b> (c) </p> (d) </u> -
4.📋 What number does the browser show next to “Grapes”?
<ol>
<li>Litchi</li>
<li>Papaya</li>
<li>Guava</li>
<li>Orange</li>
<li>Jamun</li>
<li>Grapes</li>
</ol> -
5.📋 What number does the browser show next to “Litchi”?
<ol start="3">
<li>Mango</li>
<li>Litchi</li>
<li>Grapes</li>
<li>Guava</li>
</ol> - 6.🔠 Which heading shows the SMALLEST text: <h2>, <h5>, <h3> or <h4>? (a) <h3> (b) <h4> (c) <h5> (d) <h2>
- 7.🏷️ Is </body> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 8.🔠 Which heading shows the SMALLEST text: <h1>, <h3>, <h5> or <h2>? (a) <h2> (b) <h1> (c) <h3> (d) <h5>
- 9.Which of these has a closing tag? (a) <meta> (b) <b> (c) <hr> (d) <br>
- 10.🖼️ Which tag puts a picture on a page? (a) <img> (b) <a> (c) <pic> (d) <p>
- 11.🔠 Which heading shows the SMALLEST text: <h5>, <h1>, <h4> or <h2>? (a) <h5> (b) <h2> (c) <h1> (d) <h4>
- 12.📋 Which list tag is an unordered list? (a) <ol> (b) <li> (c) <ul>
- 13.True or false: HTML on its own cannot make tables. (a) True (b) False
- 14.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 15.True or false: HTML on its own can add up two numbers. (a) False (b) True
-
16.🔍 One closing tag is missing. Which one?
<h1>I love mangoes.
<i>The red kite</i>
<h2>Our school trip</h2> (a) </i> (b) </h2> (c) </small> (d) </h1> - 17.💬 How does an HTML comment start? (a) # (b) <!-- (c) /* (d) //
-
18.🔍 One closing tag is missing. Which one?
<i>The red kite</i>
<strong>Our school trip
<em>My pets</em> (a) </em> (b) </i> (c) </strong> (d) </h3> -
19.💬 Which text will NOT show on the page?
<p>Our school trip</p>
<!-- <p>I love mangoes.</p> -->
<p>Cricket is fun.</p>
<p>My best friend</p> (a) Cricket is fun. (b) Our school trip (c) I love mangoes. (d) My best friend -
20.🔠 How many headings are in this code?
<h1>Cricket is fun.</h1>
<p>Rain today</p>
<p>Good morning!</p> -
21.🖼️ How many pixels wide is the picture drawn?
<img src="cake.jpg" alt="Birthday cake" width="350"> - 22.🏷️ Which is the closing tag for <p>? (a) <p> (b) <\p> (c) </p> (d) <p/>
- 23.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as one space (c) as 5 spaces (d) as a new line
-
24.📝 How many paragraphs does this code make?
<p>My pets</p>
<p>Fun facts</p>
<p>Cricket is fun.</p>
<h2>Hello, world!</h2>
<p>My pets</p> -
25.🔍 One closing tag is missing. Which one?
<h3>My best friend
<i>Hello, world!</i>
<u>Rain today</u> (a) </u> (b) </h3> (c) </strong> (d) </i> - 26.📋 Which list suits a shopping list in any order? (a) <hr> (b) <br> (c) <ol> (d) <ul>
- 27.📋 Which list tag lists steps in order? (a) <li> (b) <ol> (c) <ul>
-
28.🔗 Which address opens when you click this link?
<a href="games.html">Visit the site</a> (a) about.html (b) contact.html (c) games.html (d) Visit the site - 29.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 30.True or false: in <img>, src tells which image to load. (a) True (b) False
- 31.🔢 In a basic web page file, which comes FIRST? (a) <head> (b) </head> (c) <!DOCTYPE html> (d) </body>
- 32.🏷️ Every HTML tag starts with which sign? (a) ( (b) { (c) [ (d) <
-
33.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<!-- <p>The red kite</p> -->
<p>Good morning!</p>
<p>Rain today</p> -
34.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Class 7 Blog</title>
</head>
<body>
<h1>Easy snacks</h1>
<p>I like to read.</p>
</body>
</html> (a) index.html (b) I like to read. (c) Easy snacks (d) Class 7 Blog - 35.📝 What does <br> do? (a) adds a picture (b) makes a list (c) makes text bold (d) starts a new line
- 36.📄 Where does <meta charset="utf-8"> go: in the head or in the body? (a) in the head (b) in the body
-
37.💬 How many paragraphs show on the page?
<p>Hello, world!</p>
<p>Rain today</p>
<!-- <p>Our school trip</p> -->
<!-- <p>My best friend</p> --> - 38.Which of these is an opening tag? (a) </title> (b) </p> (c) <body> (d) </body>
- 39.🔠 Which tag is the least important heading? (a) <h6> (b) <h3> (c) <p> (d) <h1>
- 40.📄 Where does <title> go: in the head or in the body? (a) in the body (b) in the head
Answer key
- games.html
- <ul>
- </h3>
- 6
- 4
- <h5>
- a closing tag
- <h5>
- <b>
- <img>
- <h5>
- <ul>
- False
- an opening tag
- False
- </h1>
- <!--
- </strong>
- I love mangoes.
- 1
- 350
- </p>
- as one space
- 4
- </h3>
- <ul>
- <ol>
- games.html
- No
- True
- <!DOCTYPE html>
- <
- 2
- Class 7 Blog
- starts a new line
- in the head
- 2
- <body>
- <h6>
- in the head
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids