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.💬 How many paragraphs show on the page?
<p>My pets</p>
<p>Hello, world!</p>
<!-- <p>I love mangoes.</p> --> - 2.🌐 Which one turns HTML into a page? (a) a code editor (b) a web server (c) a web browser
-
3.🔍 Which line is missing its closing tag?
line 1: <u>My pets</u>
line 2: <i>I love mangoes.
line 3: <b>Fun facts</b> (a) line 2 (b) line 1 (c) line 3 - 4.Which of these is an opening tag? (a) <h1> (b) </p> (c) </b> (d) </h1>
-
5.📋 Does this list show bullets or numbers?
<ol>
<li>Papaya</li>
<li>Litchi</li>
<li>Banana</li>
</ol> (a) numbers (b) bullets - 6.True or false: a web browser has an address bar. (a) False (b) True
- 7.🔠 How many heading levels does HTML have? (a) 3 (b) 10 (c) 6 (d) 4
-
8.🔗 Which address opens when you click this link?
<a href="https://example.com">About us</a> (a) art.html (b) maths.html (c) https://example.com (d) About us - 9.True or false: <ol> lists things in any order. (a) False (b) True
-
10.🔍 One closing tag is missing. Which one?
<h2>Hello, world!</h2>
<small>My best friend
<h1>I love mangoes.</h1> (a) </p> (b) </small> (c) </h1> (d) </h2> - 11.🌐 Which one saves our .html files? (a) a code editor (b) a web server (c) a web browser
- 12.🏷️ Every HTML tag starts with which sign? (a) [ (b) ( (c) < (d) {
- 13.🔠 Which heading shows the BIGGEST text: <h3>, <h6>, <h1> or <h2>? (a) <h1> (b) <h6> (c) <h3> (d) <h2>
- 14.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as one space (b) as 5 spaces (c) as a new line (d) as a dot
- 15.📄 Where does <img> go: in the head or in the body? (a) in the head (b) in the body
- 16.📄 Which part holds everything you see on the page? (a) the head (b) the body (c) the title (d) the doctype
- 17.Which of these is true of a web server? (a) turns HTML into a page (b) colours code to help us (c) stores a website’s files (d) is where we type code
- 18.📝 Does <input> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
19.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>All about me</h1>
<p>Here is my best one.</p>
</body>
</html> (a) index.html (b) Here is my best one. (c) All about me (d) Space Facts - 20.📄 Where does <title> go: in the head or in the body? (a) in the body (b) in the head
- 21.🏷️ Which is the closing tag for <em>? (a) <em> (b) </em> (c) <em/> (d) <\em>
-
22.🔗 Which words do you click on?
<a href="https://example.com">Visit the site</a> (a) Visit the site (b) href (c) https://example.com (d) Maths fun - 23.True or false: in <img>, height names the picture file. (a) True (b) False
- 24.True or false: HTML on its own cannot add pictures to a page. (a) False (b) True
- 25.💬 How does an HTML comment start? (a) # (b) // (c) /* (d) <!--
- 26.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a dot . (c) a slash / (d) a dollar $
- 27.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h1> or <h4>? (a) <h4> (b) <h1> (c) <h3> (d) <h2>
- 28.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <br> (c) <ul> (d) <ol>
- 29.📄 Where does the text of <title> appear? (a) in a big heading (b) nowhere (c) at the bottom (d) on the browser tab
- 30.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
31.🔍 One closing tag is missing. Which one?
<p>Good morning!</p>
<h2>Cricket is fun.</h2>
<small>I love mangoes. (a) </i> (b) </p> (c) </h2> (d) </small> - 32.🔠 Which heading shows the BIGGEST text: <h2>, <h4>, <h3> or <h1>? (a) <h4> (b) <h3> (c) <h1> (d) <h2>
-
33.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>Good morning!</p>
<p>Cricket is fun.</p> -
34.🔠 How many headings are in this code?
<h1>Good morning!</h1>
<h4>Good morning!</h4>
<p>My best friend</p> - 35.🔠 Which tag is used for the main title on a page? (a) <p> (b) <br> (c) <h1> (d) <h6>
- 36.🔍 Which is the odd one out? (a) answers page requests (b) hosts websites online (c) shows pages from the web (d) sends pages over the net
-
37.💬 How many paragraphs show on the page?
<p>My best friend</p>
<p>Our school trip</p>
<!-- <p>The red kite</p> --> - 38.📝 What does <br> do? (a) makes text bold (b) adds a picture (c) makes a list (d) starts a new line
- 39.Which of these goes in the head? (a) <h1> (b) <p> (c) <title> (d) <ul>
-
40.📝 How many paragraphs does this code make?
<p>I love mangoes.</p>
<p>Good morning!</p>
<p>Good morning!</p>
<p>The red kite</p>
<p>I love mangoes.</p>
<h2>The red kite</h2>
Answer key
- 2
- a web browser
- line 2
- <h1>
- numbers
- True
- 6
- https://example.com
- False
- </small>
- a code editor
- <
- <h1>
- as one space
- in the body
- the body
- stores a website’s files
- an empty tag
- Space Facts
- in the head
- </em>
- Visit the site
- False
- False
- <!--
- a slash /
- <h1>
- <ol>
- on the browser tab
- a closing tag
- </small>
- <h1>
- 2
- 2
- <h1>
- shows pages from the web
- 2
- starts a new line
- <title>
- 5
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids