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 HTML tag names usually written in small letters? (a) No (b) Yes
- 2.Which of these has a closing tag? (a) <ul> (b) <meta> (c) <br> (d) <hr>
- 3.🔠 Which heading shows the SMALLEST text: <h4>, <h1>, <h6> or <h2>? (a) <h4> (b) <h2> (c) <h1> (d) <h6>
- 4.🔗 Which code links to about.html? (a) <a href="about.html"> (b) <link about.html> (c) <a alt="about.html"> (d) <a src="about.html">
- 5.True or false: <li> has a closing tag. (a) True (b) False
- 6.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 7.True or false: HTML on its own can make bullet lists. (a) False (b) True
- 8.📝 Does <meta> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
-
9.🔗 Which words do you click on?
<a href="games.html">About us</a> (a) href (b) games.html (c) About us (d) Contact us - 10.True or false: <meta> has a closing tag. (a) True (b) False
- 11.🔍 Which is the odd one out? (a) opens web pages for us (b) shows pages from the web (c) shows line numbers (d) has an address bar
- 12.💬 Why do coders write comments? (a) to add colour (b) to show pictures (c) to leave notes (d) to make links
- 13.🏷️ Every HTML tag starts with which sign? (a) [ (b) { (c) < (d) (
- 14.🖼️ Which attribute of <img> names the picture file? (a) width (b) alt (c) height (d) src
- 15.True or false: HTML on its own can count button clicks. (a) False (b) True
- 16.Which of these is an opening tag? (a) </p> (b) </li> (c) </title> (d) <p>
- 17.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h2> or <h3>? (a) <h4> (b) <h1> (c) <h3> (d) <h2>
- 18.📄 Where does <title> go: in the head or in the body? (a) in the head (b) in the body
- 19.🌐 Which one opens web pages for us? (a) a web browser (b) a web server (c) a code editor
- 20.📄 Where does the text of <title> appear? (a) at the bottom (b) in a big heading (c) nowhere (d) on the browser tab
- 21.Which of these is a closing tag? (a) <h1> (b) <p> (c) </h1> (d) <body>
- 22.True or false: <ul> shows bullet points. (a) True (b) False
-
23.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<p>My pets</p>
<p>Rain today</p>
<p>Cricket is fun.</p>
<p>Fun facts</p> - 24.📋 Which list suits a shopping list in any order? (a) <br> (b) <hr> (c) <ul> (d) <ol>
- 25.🖼️ Which attribute of <img> sets how wide it is? (a) height (b) src (c) alt (d) width
-
26.🔗 Which words do you click on?
<a href="quiz.html">Play games</a> (a) About us (b) href (c) quiz.html (d) Play games - 27.🔍 Which is the odd one out? (a) saves our .html files (b) sends pages over the net (c) shows line numbers (d) is where we type code
-
28.🔗 Which address opens when you click this link?
<a href="art.html">Contact us</a> (a) Contact us (b) quiz.html (c) art.html (d) news.html -
29.🔍 One closing tag is missing. Which one?
<u>My pets</u>
<strong>Cricket is fun.
<h2>I love mangoes.</h2> (a) </u> (b) </h2> (c) </strong> (d) </h1> - 30.💬 How does an HTML comment start? (a) <!-- (b) // (c) # (d) /*
- 31.🔠 Which heading shows the BIGGEST text: <h2>, <h6>, <h3> or <h5>? (a) <h3> (b) <h5> (c) <h6> (d) <h2>
-
32.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Class 7 Blog</title>
</head>
<body>
<h1>Match report</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) body (b) Class 7 Blog (c) Thanks for visiting. (d) Match report - 33.📝 What does <hr> draw? (a) a link (b) a table (c) a line across the page (d) a picture
- 34.🏷️ Is </li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 35.True or false: <li> lists things in any order. (a) False (b) True
-
36.🔗 Which words do you click on?
<a href="https://example.com">About us</a> (a) Contact us (b) https://example.com (c) href (d) About us - 37.True or false: a web browser shows pages from the web. (a) False (b) True
- 38.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
-
39.🔗 Which words do you click on?
<a href="about.html">Contact us</a> (a) href (b) Visit the site (c) Contact us (d) about.html - 40.🔠 Which heading shows the SMALLEST text: <h6>, <h3>, <h2> or <h1>? (a) <h3> (b) <h2> (c) <h1> (d) <h6>
Answer key
- Yes
- <ul>
- <h6>
- <a href="about.html">
- True
- No
- True
- an empty tag
- About us
- False
- shows line numbers
- to leave notes
- <
- src
- False
- <p>
- <h1>
- in the head
- a web browser
- on the browser tab
- </h1>
- True
- 1
- <ul>
- width
- Play games
- sends pages over the net
- art.html
- </strong>
- <!--
- <h2>
- Match report
- a line across the page
- a closing tag
- False
- About us
- True
- Yes
- Contact us
- <h6>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids