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 list suits a shopping list in any order? (a) <hr> (b) <br> (c) <ol> (d) <ul>
- 2.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h4> or <h2>? (a) <h1> (b) <h2> (c) <h4> (d) <h6>
-
3.📝 How many paragraphs does this code make?
<p>My pets</p>
<p>Good morning!</p>
<p>My best friend</p> - 4.🌐 Which one answers page requests? (a) a web browser (b) a web server (c) a code editor
-
5.🔍 One closing tag is missing. Which one?
<p>Fun facts</p>
<small>Our school trip
<b>I love mangoes.</b> (a) </em> (b) </p> (c) </small> (d) </b> - 6.Which of these is true of a web server? (a) saves our .html files (b) shows pages from the web (c) shows line numbers (d) hosts websites online
- 7.🏷️ Is </b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
8.🔗 Which address opens when you click this link?
<a href="quiz.html">Visit the site</a> (a) Visit the site (b) quiz.html (c) about.html (d) games.html - 9.🔠 Which heading shows the BIGGEST text: <h5>, <h6>, <h3> or <h2>? (a) <h6> (b) <h2> (c) <h3> (d) <h5>
- 10.🔠 Which tag is used for the main title on a page? (a) <h1> (b) <br> (c) <h6> (d) <p>
-
11.🔍 One closing tag is missing. Which one?
<h1>I love mangoes.
<strong>Cricket is fun.</strong>
<p>Hello, world!</p> (a) </strong> (b) </h1> (c) </p> (d) </u> - 12.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
- 13.🌐 Which one stores a website’s files? (a) a web browser (b) a web server (c) a code editor
-
14.🔗 Which words do you click on?
<a href="art.html">Maths fun</a> (a) Art corner (b) href (c) Maths fun (d) art.html - 15.Which of these is a closing tag? (a) <title> (b) <b> (c) <li> (d) </body>
- 16.True or false: <li> lists things in any order. (a) False (b) True
-
17.🔗 Which words do you click on?
<a href="games.html">Visit the site</a> (a) Maths fun (b) Visit the site (c) href (d) games.html -
18.💬 Which text will NOT show on the page?
<p>Our school trip</p>
<p>Fun facts</p>
<p>Hello, world!</p>
<!-- <p>My pets</p> --> (a) Hello, world! (b) Fun facts (c) Our school trip (d) My pets -
19.💬 How many paragraphs show on the page?
<p>The red kite</p>
<p>My pets</p>
<!-- <p>Cricket is fun.</p> --> - 20.Which of these has a closing tag? (a) <img> (b) <b> (c) <br> (d) <meta>
- 21.Which of these is an opening tag? (a) </b> (b) </p> (c) </title> (d) <li>
-
22.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Art Gallery</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) Thanks for visiting. (b) Art Gallery (c) index.html (d) Welcome! -
23.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>Cricket is fun.</p>
<p>Hello, world!</p> (a) Hello, world! (b) Cricket is fun. (c) Our school trip - 24.Which of these is true of a code editor? (a) shows pages from the web (b) shows line numbers (c) hosts websites online (d) opens web pages for us
- 25.🖼️ Which attribute of <img> describes the picture? (a) src (b) alt (c) height (d) width
-
26.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>Rain today</p>
<!-- <p>Cricket is fun.</p> -->
<!-- <p>Fun facts</p> --> - 27.Which of these goes in the head? (a) <ul> (b) <img> (c) <p> (d) <link rel="stylesheet">
-
28.🖼️ How many pixels wide is the picture drawn?
<img src="bus.jpg" alt="Our school bus" width="250"> - 29.🔗 What does target="_blank" do to a link? (a) makes it blank (b) makes it bold (c) opens it in a new tab (d) hides the link
- 30.📝 What does <p> make? (a) a picture (b) a link (c) a paragraph (d) a table
-
31.🖼️ 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) Birthday cake (c) width (d) Map of India - 32.📋 Which list tag is an unordered list? (a) <ul> (b) <li> (c) <ol>
- 33.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h1> or <h5>? (a) <h5> (b) <h6> (c) <h1> (d) <h3>
-
34.📝 How many paragraphs does this code make?
<p>My best friend</p>
<h2>Good morning!</h2>
<p>Rain today</p>
<p>Good morning!</p>
<h2>Our school trip</h2> -
35.📝 How many paragraphs does this code make?
<p>My best friend</p>
<p>The red kite</p>
<p>Good morning!</p>
<h2>I love mangoes.</h2>
<h2>Our school trip</h2> -
36.🔠 How many headings are in this code?
<h1>The red kite</h1>
<p>Fun facts</p>
<p>Good morning!</p>
<p>The red kite</p> -
37.💬 Which text will NOT show on the page?
<p>Good morning!</p>
<p>My pets</p>
<p>My best friend</p>
<!-- <p>I love mangoes.</p> --> (a) My best friend (b) Good morning! (c) I love mangoes. (d) My pets - 38.🏷️ Is <p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 39.True or false: <li> is an unordered list. (a) False (b) True
-
40.🔗 Which address opens when you click this link?
<a href="about.html">About us</a> (a) About us (b) contact.html (c) about.html (d) https://example.com
Answer key
- <ul>
- <h1>
- 3
- a web server
- </small>
- hosts websites online
- a closing tag
- quiz.html
- <h2>
- <h1>
- </h1>
- Yes
- a web server
- Maths fun
- </body>
- False
- Visit the site
- My pets
- 2
- <b>
- <li>
- Art Gallery
- Our school trip
- shows line numbers
- alt
- 1
- <link rel="stylesheet">
- 250
- opens it in a new tab
- a paragraph
- Map of India
- <ul>
- <h1>
- 3
- 3
- 1
- I love mangoes.
- an opening tag
- False
- about.html
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids