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.True or false: a web browser hosts websites online. (a) True (b) False
-
2.🔍 One closing tag is missing. Which one?
<p>Hello, world!
<h2>Cricket is fun.</h2>
<h3>Our school trip</h3> (a) </p> (b) </h3> (c) </i> (d) </h2> - 3.📋 Which tag goes around each item of a list? (a) <ul> (b) <ol> (c) <li> (d) <p>
- 4.🌐 Which one colours code to help us? (a) a web server (b) a web browser (c) a code editor
-
5.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="300"> (a) A happy dog (b) Birthday cake (c) width (d) cake.jpg - 6.🏷️ Every HTML tag starts with which sign? (a) [ (b) < (c) ( (d) {
- 7.Which of these is true of a web browser? (a) opens web pages for us (b) stores a website’s files (c) saves our .html files (d) answers page requests
-
8.📝 How many paragraphs does this code make?
<p>Cricket is fun.</p>
<h2>I love mangoes.</h2>
<h2>I love mangoes.</h2>
<p>I love mangoes.</p> -
9.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>My pets</p>
<!-- <p>Hello, world!</p> --> - 10.📋 Which list tag shows 1, 2, 3 numbers? (a) <li> (b) <ul> (c) <ol>
-
11.📋 How many items does this list show?
<ul>
<li>Guava</li>
<li>Grapes</li>
<li>Jamun</li>
<li>Orange</li>
</ul> -
12.🔠 How many headings are in this code?
<h1>The red kite</h1>
<p>My pets</p>
<h3>Our school trip</h3>
<h3>Hello, world!</h3>
<p>Cricket is fun.</p> - 13.🔠 How many heading levels does HTML have? (a) 4 (b) 3 (c) 6 (d) 10
- 14.🔍 Which is the odd one out? (a) is where we type code (b) colours code to help us (c) turns HTML into a page (d) saves our .html files
-
15.💬 Which text will NOT show on the page?
<p>The red kite</p>
<!-- <p>My pets</p> -->
<p>Rain today</p> (a) My pets (b) The red kite (c) Rain today - 16.🏷️ Which is the closing tag for <small>? (a) <small> (b) <small/> (c) <\small> (d) </small>
- 17.🔍 Which is the odd one out? (a) opens web pages for us (b) shows pages from the web (c) has an address bar (d) stores a website’s files
- 18.🔗 Which tag makes a clickable link? (a) <link> (b) <a> (c) <p> (d) <img>
-
19.💬 Which text will NOT show on the page?
<p>Hello, world!</p>
<!-- <p>The red kite</p> -->
<p>Good morning!</p>
<p>My pets</p> (a) My pets (b) Good morning! (c) The red kite (d) Hello, world! - 20.🔢 In a basic web page file, which comes first: “<body>” or “<head>”? (a) <head> (b) <body>
- 21.True or false: a code editor turns HTML into a page. (a) True (b) False
-
22.💬 How many paragraphs show on the page?
<p>The red kite</p>
<!-- <p>Rain today</p> -->
<!-- <p>My pets</p> -->
<!-- <p>Our school trip</p> -->
<!-- <p>Cricket is fun.</p> --> - 23.True or false: HTML on its own can add pictures to a page. (a) True (b) False
- 24.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 25.🖼️ Which attribute of <img> describes the picture? (a) alt (b) width (c) src (d) height
-
26.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>All about me</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) Cricket Club (b) Thanks for visiting. (c) All about me (d) body - 27.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as one space (b) as a dot (c) as a new line (d) as 5 spaces
- 28.🔤 In “HTML”, what does the M stand for? (a) Machine (b) Markup (c) Modern (d) Mouse
- 29.🔠 Which tag is the least important heading? (a) <p> (b) <h3> (c) <h6> (d) <h1>
- 30.True or false: <li> is an unordered list. (a) True (b) False
- 31.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <ol> (c) <br> (d) <hr>
-
32.💬 Which text will NOT show on the page?
<p>Fun facts</p>
<p>My best friend</p>
<p>The red kite</p>
<!-- <p>Cricket is fun.</p> --> (a) Fun facts (b) Cricket is fun. (c) The red kite (d) My best friend - 33.True or false: <br> has a closing tag. (a) False (b) True
- 34.Which of these is an opening tag? (a) </li> (b) </p> (c) </body> (d) <p>
-
35.💬 How many paragraphs show on the page?
<!-- <p>I love mangoes.</p> -->
<!-- <p>My pets</p> -->
<!-- <p>Rain today</p> -->
<p>Fun facts</p>
<p>Good morning!</p> - 36.True or false: HTML on its own can make bullet lists. (a) False (b) True
-
37.💬 How many paragraphs show on the page?
<!-- <p>Rain today</p> -->
<p>I love mangoes.</p>
<!-- <p>Good morning!</p> -->
<!-- <p>Fun facts</p> --> - 38.📋 Which list tag lists things in any order? (a) <ul> (b) <ol> (c) <li>
- 39.📄 Where does <link rel="stylesheet"> go: in the head or in the body? (a) in the head (b) in the body
- 40.🔠 Which heading shows the BIGGEST text: <h6>, <h4>, <h1> or <h2>? (a) <h4> (b) <h1> (c) <h6> (d) <h2>
Answer key
- False
- </p>
- <li>
- a code editor
- Birthday cake
- <
- opens web pages for us
- 2
- 1
- <ol>
- 4
- 3
- 6
- turns HTML into a page
- My pets
- </small>
- stores a website’s files
- <a>
- The red kite
- <head>
- False
- 1
- True
- an opening tag
- alt
- All about me
- as one space
- Markup
- <h6>
- False
- <ol>
- Cricket is fun.
- False
- <p>
- 2
- True
- 1
- <ul>
- in the head
- <h1>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids