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 does an HTML comment end? (a) >> (b) */ (c) // (d) -->
-
2.🔗 Which address opens when you click this link?
<a href="news.html">Take the quiz</a> (a) quiz.html (b) games.html (c) Take the quiz (d) news.html -
3.💬 How many paragraphs show on the page?
<!-- <p>Our school trip</p> -->
<p>Good morning!</p>
<!-- <p>I love mangoes.</p> -->
<p>Fun facts</p>
<p>Cricket is fun.</p> - 4.True or false: <h1> goes in the head. (a) True (b) False
-
5.📝 How many paragraphs does this code make?
<p>The red kite</p>
<p>Rain today</p>
<p>Hello, world!</p>
<p>Hello, world!</p> -
6.💬 Which text will NOT show on the page?
<p>Rain today</p>
<p>My pets</p>
<!-- <p>Hello, world!</p> -->
<p>Our school trip</p> (a) Rain today (b) Our school trip (c) Hello, world! (d) My pets -
7.🔗 Which address opens when you click this link?
<a href="about.html">Take the quiz</a> (a) about.html (b) contact.html (c) Take the quiz (d) https://example.com - 8.🔤 In “HTML”, what does the L stand for? (a) Language (b) Link (c) Laptop (d) Line
-
9.🔠 How many headings are in this code?
<h1>Our school trip</h1>
<p>Good morning!</p>
<p>Our school trip</p>
<h4>Fun facts</h4> - 10.True or false: HTML on its own cannot run a game loop. (a) False (b) True
- 11.Which of these is a closing tag? (a) <body> (b) <h1> (c) <title> (d) </h1>
- 12.🔠 How many heading levels does HTML have? (a) 10 (b) 3 (c) 6 (d) 4
- 13.True or false: in <img>, width sets how wide it is. (a) True (b) False
- 14.🔠 Which heading shows the SMALLEST text: <h2>, <h4>, <h5> or <h3>? (a) <h5> (b) <h2> (c) <h3> (d) <h4>
-
15.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="350"> (a) A red kite (b) Map of India (c) width (d) kite.png - 16.Which of these goes in the body? (a) <title> (b) <ul> (c) <meta charset="utf-8"> (d) <style>
- 17.Which of these has a closing tag? (a) <li> (b) <br> (c) <input> (d) <meta>
- 18.📋 Which list tag is one item of a list? (a) <ol> (b) <ul> (c) <li>
- 19.🔠 Which heading shows the SMALLEST text: <h4>, <h6>, <h2> or <h5>? (a) <h6> (b) <h4> (c) <h2> (d) <h5>
- 20.🏷️ Which is the closing tag for <em>? (a) </em> (b) <em/> (c) <em> (d) <\em>
- 21.🔍 Which is the odd one out? (a) sends pages over the net (b) turns HTML into a page (c) opens web pages for us (d) has an address bar
- 22.True or false: HTML on its own can make a form. (a) False (b) True
-
23.📋 Does this list show bullets or numbers?
<ul>
<li>Papaya</li>
<li>Litchi</li>
<li>Jamun</li>
</ul> (a) numbers (b) bullets - 24.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a slash / (c) a dollar $ (d) a dot .
-
25.💬 How many paragraphs show on the page?
<p>Rain today</p>
<!-- <p>Our school trip</p> -->
<p>I love mangoes.</p>
<p>Hello, world!</p>
<p>Fun facts</p> -
26.💬 Which text will NOT show on the page?
<p>Good morning!</p>
<!-- <p>The red kite</p> -->
<p>Cricket is fun.</p>
<p>I love mangoes.</p> (a) Cricket is fun. (b) I love mangoes. (c) Good morning! (d) The red kite - 27.📝 Does <ul> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 28.True or false: in <img>, src sets how wide it is. (a) True (b) False
-
29.🖼️ How many pixels wide is the picture drawn?
<img src="kite.png" alt="A red kite" width="300"> - 30.True or false: in <img>, src names the picture file. (a) True (b) False
-
31.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Roses are red<br>Kites fly high</p> - 32.📄 What is the first line of an HTML5 page? (a) <!DOCTYPE html> (b) <body> (c) <head> (d) <html>
-
33.💬 How many paragraphs show on the page?
<!-- <p>Cricket is fun.</p> -->
<p>Our school trip</p>
<!-- <p>I love mangoes.</p> -->
<p>My pets</p> - 34.True or false: HTML on its own can keep a high score. (a) True (b) False
- 35.💬 How does an HTML comment start? (a) /* (b) // (c) <!-- (d) #
- 36.Which of these is true of a web server? (a) shows pages from the web (b) opens web pages for us (c) hosts websites online (d) shows line numbers
- 37.True or false: HTML on its own can show paragraphs. (a) False (b) True
-
38.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="50"> (a) A tiger asleep (b) width (c) fort.jpg (d) An old fort - 39.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
- 40.Which of these has a closing tag? (a) <title> (b) <br> (c) <input> (d) <img>
Answer key
- -->
- news.html
- 3
- False
- 4
- Hello, world!
- about.html
- Language
- 2
- True
- </h1>
- 6
- True
- <h5>
- A red kite
- <ul>
- <li>
- <li>
- <h6>
- </em>
- sends pages over the net
- True
- bullets
- a slash /
- 4
- The red kite
- has a closing tag
- False
- 300
- True
- 3
- <!DOCTYPE html>
- 2
- False
- <!--
- hosts websites online
- True
- An old fort
- Yes
- <title>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids