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.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Class 7 Blog</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) Thanks for visiting. (b) Welcome! (c) body (d) Class 7 Blog - 2.📋 Which list tag shows 1, 2, 3 numbers? (a) <li> (b) <ol> (c) <ul>
- 3.True or false: <ul> goes in the head. (a) True (b) False
-
4.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<p>Hello, world!</p>
<p>My pets</p> - 5.True or false: <ol> lists steps in order. (a) True (b) False
-
6.🔍 One closing tag is missing. Which one?
<strong>Rain today
<p>Good morning!</p>
<small>I love mangoes.</small> (a) </p> (b) </small> (c) </em> (d) </strong> - 7.💾 A web page file usually ends with which extension? (a) .mp3 (b) .png (c) .txt (d) .html
- 8.🔢 In a basic web page file, which comes first: “</html>” or “<head>”? (a) </html> (b) <head>
-
9.🔠 How many headings are in this code?
<h1>My best friend</h1>
<p>The red kite</p>
<h3>The red kite</h3> -
10.📝 On how many lines does the browser show this paragraph?
<p>Roses are red<br>Birds sing<br>Sky is blue<br>Rivers flow<br>Stars shine</p> - 11.📋 Which tag goes around each item of a list? (a) <ul> (b) <li> (c) <ol> (d) <p>
- 12.📄 Can HTML on its own show paragraphs? (a) Yes (b) No
- 13.🔠 How many heading levels does HTML have? (a) 6 (b) 4 (c) 10 (d) 3
- 14.🔠 Which heading shows the BIGGEST text: <h5>, <h1>, <h4> or <h2>? (a) <h2> (b) <h5> (c) <h1> (d) <h4>
- 15.🖼️ Why do we add alt text to an image? (a) to describe the image (b) to load it faster (c) to make it bigger (d) to colour it
- 16.🔠 Which heading shows the SMALLEST text: <h1>, <h5>, <h4> or <h6>? (a) <h6> (b) <h1> (c) <h4> (d) <h5>
-
17.💬 How many paragraphs show on the page?
<!-- <p>I love mangoes.</p> -->
<!-- <p>Cricket is fun.</p> -->
<!-- <p>The red kite</p> -->
<p>Our school trip</p> - 18.Which of these goes in the body? (a) <style> (b) <title> (c) <meta charset="utf-8"> (d) <ul>
- 19.🔠 Are headings shown in bold by default? (a) Yes (b) No
- 20.📝 What does <p> make? (a) a table (b) a link (c) a paragraph (d) a picture
- 21.📄 Where does the text of <title> appear? (a) on the browser tab (b) in a big heading (c) at the bottom (d) nowhere
-
22.📋 Does this list show bullets or numbers?
<ol>
<li>Banana</li>
<li>Jamun</li>
<li>Litchi</li>
</ol> (a) bullets (b) numbers - 23.True or false: a web browser shows pages from the web. (a) True (b) False
- 24.True or false: in <img>, alt tells which image to load. (a) False (b) True
- 25.True or false: in <img>, src names the picture file. (a) False (b) True
- 26.True or false: <table> goes in the head. (a) False (b) True
- 27.True or false: a code editor opens web pages for us. (a) True (b) False
- 28.True or false: HTML on its own can add up two numbers. (a) True (b) False
- 29.🔠 Which heading shows the SMALLEST text: <h6>, <h5>, <h2> or <h4>? (a) <h4> (b) <h6> (c) <h2> (d) <h5>
- 30.🏷️ Which is the closing tag for <h1>? (a) <h1> (b) <\h1> (c) </h1> (d) <h1/>
- 31.💬 Why do coders write comments? (a) to add colour (b) to leave notes (c) to show pictures (d) to make links
-
32.🔗 Which words do you click on?
<a href="quiz.html">Maths fun</a> (a) href (b) Maths fun (c) quiz.html (d) Art corner - 33.💬 Does the browser show comments on the page? (a) No (b) Yes
- 34.🏷️ Which is the closing tag for <u>? (a) <u> (b) <u/> (c) </u> (d) <\u>
-
35.🔗 Which address opens when you click this link?
<a href="news.html">Play games</a> (a) Play games (b) news.html (c) quiz.html (d) games.html -
36.📝 On how many lines does the browser show this paragraph?
<p>Stars shine<br>Rivers flow<br>Birds sing<br>Kites fly high</p> -
37.🔗 Where does this link open?
<a href="about.html" target="_blank">Contact us</a> (a) in the same tab (b) in a new tab - 38.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
-
39.📋 How many items does this list show?
<ul>
<li>Mango</li>
<li>Litchi</li>
</ul> - 40.🏷️ Which is the closing tag for <strong>? (a) <strong/> (b) </strong> (c) <strong> (d) <\strong>
Answer key
- Welcome!
- <ol>
- False
- 2
- True
- </strong>
- .html
- <head>
- 2
- 5
- <li>
- Yes
- 6
- <h1>
- to describe the image
- <h6>
- 1
- <ul>
- Yes
- a paragraph
- on the browser tab
- numbers
- True
- False
- True
- False
- False
- False
- <h6>
- </h1>
- to leave notes
- Maths fun
- No
- </u>
- news.html
- 4
- in a new tab
- Yes
- 2
- </strong>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids