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 tag goes around each item of a list? (a) <p> (b) <ul> (c) <ol> (d) <li>
-
2.🔗 Where does this link open?
<a href="art.html">Play games</a> (a) in the same tab (b) in a new tab -
3.💬 How many paragraphs show on the page?
<p>Our school trip</p>
<!-- <p>Hello, world!</p> -->
<p>I love mangoes.</p>
<!-- <p>Good morning!</p> -->
<p>My pets</p> - 4.🏷️ Every HTML tag starts with which sign? (a) ( (b) < (c) { (d) [
-
5.🔗 Which words do you click on?
<a href="art.html">Visit the site</a> (a) art.html (b) Maths fun (c) href (d) Visit the site -
6.🔗 Where does this link open?
<a href="https://example.com">Take the quiz</a> (a) in a new tab (b) in the same tab - 7.🔠 Which heading shows the BIGGEST text: <h4>, <h3>, <h1> or <h6>? (a) <h4> (b) <h3> (c) <h1> (d) <h6>
-
8.💬 How many paragraphs show on the page?
<p>Rain today</p>
<!-- <p>My best friend</p> -->
<!-- <p>My pets</p> -->
<p>Good morning!</p>
<!-- <p>Our school trip</p> --> - 9.📋 Which list tag shows 1, 2, 3 numbers? (a) <ul> (b) <ol> (c) <li>
-
10.🔗 Which address opens when you click this link?
<a href="games.html">Contact us</a> (a) contact.html (b) games.html (c) Contact us (d) about.html -
11.🔗 Where does this link open?
<a href="games.html">About us</a> (a) in the same tab (b) in a new tab -
12.💬 How many paragraphs show on the page?
<p>I love mangoes.</p>
<!-- <p>My pets</p> -->
<p>Hello, world!</p>
<!-- <p>Good morning!</p> --> - 13.📝 What does <hr> draw? (a) a link (b) a picture (c) a table (d) a line across the page
- 14.📄 What is the first line of an HTML5 page? (a) <!DOCTYPE html> (b) <body> (c) <html> (d) <head>
- 15.Which of these is a closing tag? (a) <li> (b) <h1> (c) <body> (d) </li>
- 16.📄 Where does <h1> go: in the head or in the body? (a) in the body (b) in the head
- 17.📛 In <a href="x.html">, what is href? (a) a closing tag (b) an element name (c) an attribute (d) a comment
-
18.💬 How many paragraphs show on the page?
<p>Rain today</p>
<!-- <p>My pets</p> -->
<p>Our school trip</p> -
19.📋 How many items does this list show?
<ul>
<li>Mango</li>
<li>Guava</li>
<li>Litchi</li>
</ul> - 20.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h1> or <h4>? (a) <h3> (b) <h6> (c) <h1> (d) <h4>
-
21.🔗 Where does this link open?
<a href="news.html" target="_blank">About us</a> (a) in the same tab (b) in a new tab - 22.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as 5 spaces (b) as a dot (c) as one space (d) as a new line
- 23.📋 Which list tag goes inside ul or ol? (a) <li> (b) <ul> (c) <ol>
-
24.🔍 One closing tag is missing. Which one?
<h2>Hello, world!</h2>
<i>Cricket is fun.
<small>My pets</small> (a) </b> (b) </i> (c) </small> (d) </h2> -
25.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>Planets</h1>
<p>Try this poha.</p>
</body>
</html> (a) Try this poha. (b) Cricket Club (c) body (d) Planets -
26.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Art Gallery</title>
</head>
<body>
<h1>All about me</h1>
<p>I like to read.</p>
</body>
</html> (a) Art Gallery (b) All about me (c) body (d) I like to read. - 27.Which of these goes in the body? (a) <style> (b) <link rel="stylesheet"> (c) <title> (d) <img>
- 28.Which of these is an opening tag? (a) </title> (b) <li> (c) </b> (d) </h1>
-
29.💬 Which text will NOT show on the page?
<!-- <p>Fun facts</p> -->
<p>Hello, world!</p>
<p>Cricket is fun.</p> (a) Hello, world! (b) Cricket is fun. (c) Fun facts - 30.Which of these is an opening tag? (a) </b> (b) </li> (c) <b> (d) </title>
-
31.📋 How many items does this list show?
<ol>
<li>Mango</li>
<li>Jamun</li>
<li>Litchi</li>
<li>Grapes</li>
</ol> -
32.🔠 How many headings are in this code?
<h1>Rain today</h1>
<h3>The red kite</h3>
<h4>Good morning!</h4>
<p>My best friend</p> - 33.🔠 Which heading shows the BIGGEST text: <h3>, <h6>, <h2> or <h1>? (a) <h2> (b) <h1> (c) <h3> (d) <h6>
-
34.🔠 How many headings are in this code?
<h1>Cricket is fun.</h1>
<h2>Hello, world!</h2>
<h2>Our school trip</h2> - 35.True or false: <title> has a closing tag. (a) True (b) False
- 36.🔠 Which tag is used for the main title on a page? (a) <p> (b) <h6> (c) <br> (d) <h1>
- 37.🌐 Which one colours code to help us? (a) a code editor (b) a web server (c) a web browser
-
38.🔗 Which words do you click on?
<a href="art.html">About us</a> (a) Contact us (b) href (c) art.html (d) About us -
39.📋 How many items does this list show?
<ul>
<li>Grapes</li>
<li>Guava</li>
</ul> -
40.💬 How many paragraphs show on the page?
<!-- <p>Our school trip</p> -->
<p>Good morning!</p>
<p>My best friend</p>
Answer key
- <li>
- in the same tab
- 3
- <
- Visit the site
- in the same tab
- <h1>
- 2
- <ol>
- games.html
- in the same tab
- 2
- a line across the page
- <!DOCTYPE html>
- </li>
- in the body
- an attribute
- 2
- 3
- <h1>
- in a new tab
- as one space
- <li>
- </i>
- Planets
- All about me
- <img>
- <li>
- Fun facts
- <b>
- 4
- 3
- <h1>
- 3
- True
- <h1>
- a code editor
- About us
- 2
- 2
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids