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.True or false: <ol> lists steps in order. (a) False (b) True
-
2.🔍 One closing tag is missing. Which one?
<h1>My pets
<strong>My best friend</strong>
<u>Our school trip</u> (a) </strong> (b) </u> (c) </h1> (d) </em> - 3.Which of these is an empty tag? (a) <ul> (b) <br> (c) <p> (d) <b>
- 4.🌐 Which one shows pages from the web? (a) a web server (b) a code editor (c) a web browser
- 5.True or false: <p> has a closing tag. (a) True (b) False
- 6.📄 Can HTML on its own add pictures to a page? (a) No (b) Yes
-
7.🔗 Which words do you click on?
<a href="art.html">Play games</a> (a) About us (b) href (c) art.html (d) Play games - 8.True or false: <style> goes in the body. (a) True (b) False
- 9.🔢 In a basic web page file, which comes first: “</html>” or “</head>”? (a) </html> (b) </head>
- 10.Which of these has a closing tag? (a) <input> (b) <b> (c) <img> (d) <meta>
- 11.📋 Which list suits a shopping list in any order? (a) <ol> (b) <hr> (c) <ul> (d) <br>
-
12.💬 How many paragraphs show on the page?
<!-- <p>Cricket is fun.</p> -->
<!-- <p>Rain today</p> -->
<p>I love mangoes.</p> - 13.Which of these goes in the head? (a) <h1> (b) <style> (c) <p> (d) <table>
-
14.🔗 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 -
15.🔍 One closing tag is missing. Which one?
<strong>The red kite</strong>
<h3>My pets
<em>Hello, world!</em> (a) </strong> (b) </em> (c) </h3> (d) </p> -
16.📄 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>Mars is red.</p>
</body>
</html> (a) Class 7 Blog (b) Mars is red. (c) body (d) My drawings - 17.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h3> or <h2>? (a) <h3> (b) <h2> (c) <h6> (d) <h1>
-
18.🔍 One closing tag is missing. Which one?
<em>Hello, world!</em>
<b>Fun facts
<u>The red kite</u> (a) </h2> (b) </b> (c) </em> (d) </u> -
19.🔠 How many headings are in this code?
<h1>Good morning!</h1>
<h3>The red kite</h3>
<p>The red kite</p> - 20.True or false: a web server stores a website’s files. (a) True (b) False
- 21.🔠 Which tag is used for the main title on a page? (a) <p> (b) <br> (c) <h6> (d) <h1>
- 22.📄 Which part holds everything you see on the page? (a) the title (b) the doctype (c) the body (d) the head
-
23.🔗 Which words do you click on?
<a href="news.html">Maths fun</a> (a) Art corner (b) href (c) news.html (d) Maths fun - 24.🔠 Which heading shows the BIGGEST text: <h6>, <h1>, <h2> or <h3>? (a) <h3> (b) <h2> (c) <h6> (d) <h1>
-
25.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<h2>Rain today</h2>
<h2>Hello, world!</h2>
<h2>I love mangoes.</h2> - 26.📄 Can HTML on its own add up two numbers? (a) Yes (b) No
- 27.🔠 Which heading shows the BIGGEST text: <h1>, <h2>, <h4> or <h6>? (a) <h1> (b) <h4> (c) <h6> (d) <h2>
- 28.🌍 Which program shows a web page to us? (a) a calculator (b) a music player (c) a paint program (d) a web browser
- 29.Which of these is true of a code editor? (a) sends pages over the net (b) answers page requests (c) shows line numbers (d) has an address bar
-
30.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<h4>The red kite</h4>
<p>I love mangoes.</p>
<h4>Fun facts</h4> - 31.True or false: HTML on its own can make links to pages. (a) False (b) True
- 32.True or false: a web server answers page requests. (a) False (b) True
-
33.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="100"> (a) A red kite (b) width (c) Map of India (d) kite.png - 34.📄 Where does <ul> go: in the head or in the body? (a) in the head (b) in the body
-
35.💬 How many paragraphs show on the page?
<!-- <p>Cricket is fun.</p> -->
<!-- <p>My best friend</p> -->
<p>Fun facts</p> -
36.💬 How many paragraphs show on the page?
<!-- <p>My pets</p> -->
<!-- <p>The red kite</p> -->
<!-- <p>Rain today</p> -->
<!-- <p>Good morning!</p> -->
<p>My best friend</p> -
37.🔍 Which line is missing its closing tag?
line 1: <b>Good morning!</b>
line 2: <u>I love mangoes.</u>
line 3: <strong>Rain today (a) line 3 (b) line 1 (c) line 2 -
38.📝 On how many lines does the browser show this paragraph?
<p>Roses are red<br>Birds sing</p> -
39.📋 What number does the browser show next to “Litchi”?
<ol start="7">
<li>Banana</li>
<li>Litchi</li>
<li>Mango</li>
</ol> -
40.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>Match report</h1>
<p>Try this poha.</p>
</body>
</html> (a) Space Facts (b) Try this poha. (c) Match report (d) body
Answer key
- True
- </h1>
- <br>
- a web browser
- True
- Yes
- Play games
- False
- </head>
- <b>
- <ul>
- 1
- <style>
- in a new tab
- </h3>
- My drawings
- <h6>
- </b>
- 2
- True
- <h1>
- the body
- Maths fun
- <h1>
- 4
- No
- <h1>
- a web browser
- shows line numbers
- 3
- True
- True
- A red kite
- in the body
- 1
- 1
- line 3
- 2
- 8
- Match report
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids