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: <title> goes in the head. (a) True (b) False
- 2.📋 Which list tag is an unordered list? (a) <ol> (b) <li> (c) <ul>
- 3.🔗 Which attribute holds the address of a link? (a) src (b) href (c) alt (d) id
-
4.💬 Which text will NOT show on the page?
<p>Good morning!</p>
<!-- <p>Our school trip</p> -->
<p>Cricket is fun.</p> (a) Cricket is fun. (b) Our school trip (c) Good morning! - 5.🔠 Which heading shows the BIGGEST text: <h5>, <h2>, <h1> or <h6>? (a) <h6> (b) <h5> (c) <h1> (d) <h2>
- 6.🔢 In a basic web page file, which comes FIRST? (a) </head> (b) <!DOCTYPE html> (c) <head> (d) <body>
-
7.📋 Does this list show bullets or numbers?
<ul>
<li>Papaya</li>
<li>Mango</li>
</ul> (a) bullets (b) numbers - 8.True or false: <ol> is an unordered list. (a) False (b) True
- 9.🔠 Which heading shows the SMALLEST text: <h6>, <h3>, <h1> or <h5>? (a) <h3> (b) <h1> (c) <h6> (d) <h5>
-
10.📋 Does this list show bullets or numbers?
<ul>
<li>Orange</li>
<li>Banana</li>
</ul> (a) numbers (b) bullets -
11.💬 Which text will NOT show on the page?
<p>I love mangoes.</p>
<p>Rain today</p>
<!-- <p>Our school trip</p> --> (a) I love mangoes. (b) Rain today (c) Our school trip - 12.📄 Can HTML on its own make links to pages? (a) No (b) Yes
- 13.True or false: HTML on its own can count button clicks. (a) True (b) False
- 14.🏷️ Which is the closing tag for <h1>? (a) <h1> (b) <\h1> (c) </h1> (d) <h1/>
- 15.🏷️ Which is the closing tag for <em>? (a) <\em> (b) <em> (c) </em> (d) <em/>
- 16.True or false: <img> has a closing tag. (a) False (b) True
-
17.🔗 Which words do you click on?
<a href="games.html">About us</a> (a) href (b) About us (c) games.html (d) Contact us - 18.🔠 Which heading shows the SMALLEST text: <h2>, <h3>, <h4> or <h1>? (a) <h1> (b) <h4> (c) <h2> (d) <h3>
-
19.🔗 Which address opens when you click this link?
<a href="quiz.html">Contact us</a> (a) quiz.html (b) Contact us (c) games.html (d) about.html - 20.🔠 Which heading shows the BIGGEST text: <h5>, <h3>, <h6> or <h4>? (a) <h4> (b) <h3> (c) <h6> (d) <h5>
-
21.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="200"> (a) kite.png (b) A red kite (c) cake.jpg (d) map.png - 22.🔠 How many <h1> headings should a page usually have? (a) 6 (b) 1 (c) 3 (d) 10
-
23.🔍 Which line is missing its closing tag?
line 1: <strong>My best friend</strong>
line 2: <h1>Fun facts
line 3: <small>Hello, world!</small> (a) line 2 (b) line 1 (c) line 3 - 24.📋 Which tag goes around each item of a list? (a) <p> (b) <ol> (c) <ul> (d) <li>
- 25.True or false: <table> goes in the body. (a) True (b) False
-
26.💬 How many paragraphs show on the page?
<p>Hello, world!</p>
<!-- <p>My best friend</p> -->
<p>Our school trip</p>
<p>Fun facts</p> - 27.🖼️ Which attribute of <img> describes the picture? (a) src (b) height (c) alt (d) width
- 28.🔠 Which heading shows the SMALLEST text: <h2>, <h1>, <h6> or <h5>? (a) <h6> (b) <h2> (c) <h1> (d) <h5>
-
29.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Our school trip</h2>
<h2>Hello, world!</h2>
<h2>The red kite</h2> - 30.True or false: in <img>, height tells which image to load. (a) True (b) False
-
31.🔗 Which words do you click on?
<a href="contact.html">Art corner</a> (a) Art corner (b) School news (c) href (d) contact.html -
32.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>My Hobbies</title>
</head>
<body>
<h1>My drawings</h1>
<p>Try this poha.</p>
</body>
</html> (a) My drawings (b) Try this poha. (c) index.html (d) My Hobbies - 33.🔠 Which heading shows the SMALLEST text: <h1>, <h3>, <h6> or <h5>? (a) <h3> (b) <h6> (c) <h1> (d) <h5>
-
34.📋 Does this list show bullets or numbers?
<ol>
<li>Grapes</li>
<li>Jamun</li>
</ol> (a) bullets (b) numbers - 35.💬 How does an HTML comment start? (a) # (b) // (c) /* (d) <!--
-
36.🔗 Which address opens when you click this link?
<a href="art.html">About us</a> (a) art.html (b) quiz.html (c) About us (d) news.html -
37.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Mars is red.</p>
</body>
</html> (a) Mars is red. (b) body (c) Space Facts (d) Welcome! -
38.🔍 Which line is missing its closing tag?
line 1: <small>Fun facts</small>
line 2: <h3>Cricket is fun.</h3>
line 3: <em>Hello, world! (a) line 2 (b) line 3 (c) line 1 - 39.📄 Which part holds everything you see on the page? (a) the doctype (b) the title (c) the body (d) the head
- 40.🔗 Which code links to about.html? (a) <a src="about.html"> (b) <link about.html> (c) <a href="about.html"> (d) <a alt="about.html">
Answer key
- True
- <ul>
- href
- Our school trip
- <h1>
- <!DOCTYPE html>
- bullets
- False
- <h6>
- bullets
- Our school trip
- Yes
- False
- </h1>
- </em>
- False
- About us
- <h4>
- quiz.html
- <h3>
- kite.png
- 1
- line 2
- <li>
- True
- 3
- alt
- <h6>
- 1
- False
- Art corner
- My Hobbies
- <h6>
- numbers
- <!--
- art.html
- Welcome!
- line 3
- the body
- <a href="about.html">
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids