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.🔍 Which line is missing its closing tag?
line 1: <p>I love mangoes.</p>
line 2: <h1>My best friend</h1>
line 3: <strong>Fun facts (a) line 1 (b) line 2 (c) line 3 - 2.📝 What does <hr> draw? (a) a picture (b) a table (c) a link (d) a line across the page
- 3.💬 Does the browser show comments on the page? (a) Yes (b) No
- 4.📛 In <a href="x.html">, what is href? (a) a comment (b) an element name (c) an attribute (d) a closing tag
- 5.Which of these goes in the head? (a) <a> (b) <p> (c) <title> (d) <img>
- 6.🔠 Which heading shows the SMALLEST text: <h1>, <h6>, <h4> or <h2>? (a) <h4> (b) <h6> (c) <h2> (d) <h1>
-
7.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Stars shine</p> - 8.True or false: <title> is an empty tag. (a) False (b) True
- 9.📋 Which tag goes around each item of a list? (a) <p> (b) <li> (c) <ol> (d) <ul>
- 10.🏷️ Which is the closing tag for <em>? (a) </em> (b) <em> (c) <em/> (d) <\em>
- 11.True or false: <li> is one item of a list. (a) False (b) True
- 12.🏷️ Which is the closing tag for <h1>? (a) <h1> (b) <\h1> (c) </h1> (d) <h1/>
- 13.🔠 Which heading shows the SMALLEST text: <h2>, <h6>, <h4> or <h5>? (a) <h5> (b) <h4> (c) <h2> (d) <h6>
- 14.🔍 Which is the odd one out? (a) opens web pages for us (b) turns HTML into a page (c) shows pages from the web (d) answers page requests
- 15.Which of these is an opening tag? (a) </li> (b) </b> (c) </title> (d) <p>
-
16.🔗 Which words do you click on?
<a href="games.html">Art corner</a> (a) href (b) games.html (c) School news (d) Art corner - 17.📄 Which part holds everything you see on the page? (a) the body (b) the doctype (c) the head (d) the title
-
18.💬 Which text will NOT show on the page?
<!-- <p>Good morning!</p> -->
<p>I love mangoes.</p>
<p>My pets</p> (a) I love mangoes. (b) Good morning! (c) My pets - 19.💬 Why do coders write comments? (a) to add colour (b) to show pictures (c) to leave notes (d) to make links
- 20.🔍 Which is the odd one out? (a) hosts websites online (b) saves our .html files (c) shows line numbers (d) is where we type code
- 21.📄 Can HTML on its own make tables? (a) Yes (b) No
- 22.📋 Which list tag is an unordered list? (a) <li> (b) <ul> (c) <ol>
- 23.🔤 In “HTML”, what do the letters HT stand for? (a) Home Text (b) Hot Tags (c) HyperText (d) High Tech
- 24.📝 What do we need to write HTML? (a) a printer (b) a paintbrush (c) a plain text editor (d) a microphone
-
25.💬 Which text will NOT show on the page?
<p>Our school trip</p>
<!-- <p>My best friend</p> -->
<p>Good morning!</p> (a) Our school trip (b) My best friend (c) Good morning! - 26.📄 Can HTML on its own make links to pages? (a) Yes (b) No
-
27.🖼️ Which picture file does the browser load?
<img src="dog.jpg" alt="A happy dog" width="150"> (a) dog.jpg (b) moon.png (c) bus.jpg (d) A happy dog -
28.💬 How many paragraphs show on the page?
<p>The red kite</p>
<!-- <p>I love mangoes.</p> -->
<!-- <p>Fun facts</p> -->
<p>Hello, world!</p> -
29.💬 How many paragraphs show on the page?
<p>Rain today</p>
<p>The red kite</p>
<!-- <p>My pets</p> -->
<p>Hello, world!</p> - 30.🌐 Which one stores a website’s files? (a) a code editor (b) a web server (c) a web browser
-
31.📋 What number does the browser show next to “Banana”?
<ol>
<li>Grapes</li>
<li>Banana</li>
<li>Papaya</li>
</ol> -
32.🔍 One closing tag is missing. Which one?
<p>Good morning!</p>
<strong>The red kite</strong>
<h3>I love mangoes. (a) </strong> (b) </h3> (c) </p> (d) </b> - 33.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <ol> (c) <br> (d) <ul>
-
34.📝 How many paragraphs does this code make?
<p>The red kite</p>
<p>Cricket is fun.</p>
<p>Our school trip</p> - 35.📝 Does <input> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
36.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="100"> (a) map.png (b) Map of India (c) width (d) Birthday cake - 37.Which of these is an opening tag? (a) </body> (b) <h1> (c) </li> (d) </title>
-
38.💬 How many paragraphs show on the page?
<!-- <p>Cricket is fun.</p> -->
<p>Good morning!</p>
<p>The red kite</p> - 39.🔠 Which tag is the least important heading? (a) <h3> (b) <p> (c) <h1> (d) <h6>
- 40.📄 What is the first line of an HTML5 page? (a) <head> (b) <body> (c) <html> (d) <!DOCTYPE html>
Answer key
- line 3
- a line across the page
- No
- an attribute
- <title>
- <h6>
- 2
- False
- <li>
- </em>
- True
- </h1>
- <h6>
- answers page requests
- <p>
- Art corner
- the body
- Good morning!
- to leave notes
- hosts websites online
- Yes
- <ul>
- HyperText
- a plain text editor
- My best friend
- Yes
- dog.jpg
- 2
- 3
- a web server
- 2
- </h3>
- <ol>
- 3
- an empty tag
- Map of India
- <h1>
- 2
- <h6>
- <!DOCTYPE html>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids