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.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 2.🏷️ Which is the closing tag for <u>? (a) <u> (b) <u/> (c) <\u> (d) </u>
- 3.💬 Does the browser show comments on the page? (a) Yes (b) No
- 4.🏷️ Every HTML tag starts with which sign? (a) [ (b) { (c) < (d) (
- 5.🔠 Which heading shows the SMALLEST text: <h5>, <h2>, <h6> or <h4>? (a) <h4> (b) <h2> (c) <h6> (d) <h5>
- 6.Which of these goes in the body? (a) <style> (b) <title> (c) <h1> (d) <link rel="stylesheet">
- 7.📋 Which tag goes around each item of a list? (a) <ul> (b) <p> (c) <ol> (d) <li>
-
8.📋 How many items does this list show?
<ul>
<li>Banana</li>
<li>Mango</li>
<li>Orange</li>
<li>Grapes</li>
</ul> -
9.💬 Which text will NOT show on the page?
<p>Cricket is fun.</p>
<p>My best friend</p>
<p>Fun facts</p>
<!-- <p>Hello, world!</p> --> (a) Cricket is fun. (b) Fun facts (c) My best friend (d) Hello, world! - 10.Which of these is true of a web browser? (a) answers page requests (b) colours code to help us (c) is where we type code (d) turns HTML into a page
- 11.🔠 Are headings shown in bold by default? (a) Yes (b) No
-
12.🔗 Where does this link open?
<a href="contact.html" target="_blank">Art corner</a> (a) in the same tab (b) in a new tab - 13.True or false: HTML on its own cannot show paragraphs. (a) True (b) False
- 14.Which of these has a closing tag? (a) <meta> (b) <img> (c) <input> (d) <p>
- 15.True or false: <input> is an empty tag. (a) True (b) False
-
16.🔗 Which address opens when you click this link?
<a href="news.html">Contact us</a> (a) quiz.html (b) Contact us (c) news.html (d) games.html - 17.🏷️ Is </title> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
18.🔍 Which line is missing its closing tag?
line 1: <p>Hello, world!</p>
line 2: <em>Fun facts
line 3: <h3>I love mangoes.</h3> (a) line 3 (b) line 2 (c) line 1 - 19.💬 Why do coders write comments? (a) to add colour (b) to make links (c) to show pictures (d) to leave notes
- 20.🔗 Which tag makes a clickable link? (a) <p> (b) <a> (c) <img> (d) <link>
-
21.📋 How many items does this list show?
<ol>
<li>Litchi</li>
<li>Banana</li>
<li>Papaya</li>
<li>Grapes</li>
</ol> - 22.True or false: a code editor colours code to help us. (a) False (b) True
- 23.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h4> or <h3>? (a) <h6> (b) <h4> (c) <h3> (d) <h1>
-
24.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<!-- <p>My pets</p> -->
<p>Rain today</p>
<p>Fun facts</p> -
25.📝 How many paragraphs does this code make?
<p>Rain today</p>
<p>Fun facts</p>
<p>Good morning!</p>
<p>Hello, world!</p> - 26.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
- 27.📄 Can HTML on its own keep a high score? (a) Yes (b) No
- 28.🖼️ Which attribute of <img> tells which image to load? (a) width (b) height (c) src (d) alt
- 29.🔢 In a basic web page file, which comes first: “<html>” or “<head>”? (a) <head> (b) <html>
-
30.🖼️ Which picture file does the browser load?
<img src="bus.jpg" alt="Our school bus" width="350"> (a) Our school bus (b) fort.jpg (c) tiger.jpg (d) bus.jpg -
31.📝 How many paragraphs does this code make?
<p>Fun facts</p>
<p>Good morning!</p>
<h2>Rain today</h2>
<h2>I love mangoes.</h2> - 32.🔠 Which heading shows the SMALLEST text: <h1>, <h5>, <h3> or <h2>? (a) <h5> (b) <h2> (c) <h3> (d) <h1>
-
33.🔍 One closing tag is missing. Which one?
<p>Cricket is fun.</p>
<u>My pets</u>
<h2>The red kite (a) </p> (b) </h2> (c) </strong> (d) </u> -
34.💬 Which text will NOT show on the page?
<!-- <p>My pets</p> -->
<p>Good morning!</p>
<p>Cricket is fun.</p>
<p>Fun facts</p> (a) Cricket is fun. (b) Good morning! (c) Fun facts (d) My pets - 35.🔠 Which tag is used for the main title on a page? (a) <br> (b) <p> (c) <h6> (d) <h1>
-
36.📋 Does this list show bullets or numbers?
<ul>
<li>Grapes</li>
<li>Jamun</li>
<li>Orange</li>
</ul> (a) numbers (b) bullets -
37.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>Cricket is fun.</p>
<p>My best friend</p>
<p>Fun facts</p> (a) My best friend (b) Cricket is fun. (c) Fun facts (d) Our school trip - 38.🏷️ Which is the closing tag for <h2>? (a) <\h2> (b) </h2> (c) <h2> (d) <h2/>
- 39.📄 Where does <a> go: in the head or in the body? (a) in the head (b) in the body
- 40.🔠 Which tag is the least important heading? (a) <p> (b) <h1> (c) <h3> (d) <h6>
Answer key
- a closing tag
- </u>
- No
- <
- <h6>
- <h1>
- <li>
- 4
- Hello, world!
- turns HTML into a page
- Yes
- in a new tab
- False
- <p>
- True
- news.html
- a closing tag
- line 2
- to leave notes
- <a>
- 4
- True
- <h6>
- 2
- 4
- Yes
- No
- src
- <html>
- bus.jpg
- 2
- <h5>
- </h2>
- My pets
- <h1>
- bullets
- Our school trip
- </h2>
- in the body
- <h6>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids