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.🔤 In “HTML”, what do the letters HT stand for? (a) High Tech (b) Home Text (c) Hot Tags (d) HyperText
- 2.📄 Where does <img> go: in the head or in the body? (a) in the body (b) in the head
- 3.📄 Where does <h1> go: in the head or in the body? (a) in the head (b) in the body
- 4.True or false: <img> is an empty tag. (a) False (b) True
- 5.🔗 Which code links to about.html? (a) <a alt="about.html"> (b) <a href="about.html"> (c) <link about.html> (d) <a src="about.html">
- 6.Which of these is true of a code editor? (a) colours code to help us (b) stores a website’s files (c) turns HTML into a page (d) opens web pages for us
- 7.📝 Does <meta> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
8.🔍 One closing tag is missing. Which one?
<em>Our school trip
<strong>Cricket is fun.</strong>
<small>My pets</small> (a) </small> (b) </em> (c) </strong> (d) </i> -
9.💬 How many paragraphs show on the page?
<p>I love mangoes.</p>
<!-- <p>Fun facts</p> -->
<!-- <p>Rain today</p> --> -
10.🔗 Which words do you click on?
<a href="contact.html">School news</a> (a) School news (b) Take the quiz (c) contact.html (d) href -
11.🔗 Where does this link open?
<a href="games.html">Art corner</a> (a) in a new tab (b) in the same tab - 12.🔗 Which tag makes a clickable link? (a) <p> (b) <a> (c) <link> (d) <img>
-
13.📋 How many items does this list show?
<ol>
<li>Grapes</li>
<li>Litchi</li>
<li>Banana</li>
<li>Mango</li>
<li>Orange</li>
</ol> - 14.True or false: <input> is an empty tag. (a) True (b) False
- 15.Which of these is an opening tag? (a) <li> (b) </h1> (c) </b> (d) </p>
-
16.💬 How many paragraphs show on the page?
<!-- <p>Fun facts</p> -->
<p>Hello, world!</p>
<!-- <p>My pets</p> --> - 17.True or false: <h1> goes in the body. (a) True (b) False
- 18.🖼️ Which attribute of <img> sets how wide it is? (a) alt (b) src (c) width (d) height
- 19.True or false: <hr> is an empty tag. (a) False (b) True
- 20.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h4> or <h3>? (a) <h1> (b) <h2> (c) <h4> (d) <h3>
- 21.🏷️ HTML marks up text using ___. (a) keys (b) wires (c) pixels (d) tags
- 22.True or false: <table> goes in the head. (a) True (b) False
-
23.💬 How many paragraphs show on the page?
<!-- <p>Cricket is fun.</p> -->
<p>Rain today</p>
<p>Hello, world!</p>
<p>Fun facts</p> - 24.🔗 Which attribute holds the address of a link? (a) src (b) href (c) alt (d) id
- 25.🏷️ Which is the closing tag for <small>? (a) <\small> (b) <small> (c) <small/> (d) </small>
-
26.🔍 Which line is missing its closing tag?
line 1: <h3>My best friend</h3>
line 2: <strong>I love mangoes.
line 3: <i>Hello, world!</i> (a) line 2 (b) line 3 (c) line 1 - 27.🔠 How many heading levels does HTML have? (a) 6 (b) 3 (c) 10 (d) 4
- 28.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h3> or <h6>? (a) <h1> (b) <h6> (c) <h4> (d) <h3>
- 29.📋 Which list shows the steps of a recipe best? (a) <ol> (b) <br> (c) <ul> (d) <hr>
- 30.Which of these goes in the head? (a) <title> (b) <h1> (c) <table> (d) <ul>
- 31.True or false: <p> goes in the head. (a) False (b) True
- 32.💬 How does an HTML comment end? (a) // (b) >> (c) --> (d) */
- 33.📝 Does <p> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 34.Which of these has a closing tag? (a) <meta> (b) <hr> (c) <p> (d) <img>
- 35.🏷️ Is </p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 36.📝 Does <br> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
37.🔍 One closing tag is missing. Which one?
<u>I love mangoes.</u>
<b>My pets</b>
<p>Good morning! (a) </p> (b) </b> (c) </u> (d) </strong> -
38.🔠 How many headings are in this code?
<h1>Fun facts</h1>
<h4>Our school trip</h4>
<p>My best friend</p> - 39.True or false: in <img>, alt shows if the image fails. (a) True (b) False
-
40.🖼️ How many pixels wide is the picture drawn?
<img src="kite.png" alt="A red kite" width="100">
Answer key
- HyperText
- in the body
- in the body
- True
- <a href="about.html">
- colours code to help us
- an empty tag
- </em>
- 1
- School news
- in the same tab
- <a>
- 5
- True
- <li>
- 1
- True
- width
- True
- <h1>
- tags
- False
- 3
- href
- </small>
- line 2
- 6
- <h1>
- <ol>
- <title>
- False
- -->
- has a closing tag
- <p>
- a closing tag
- an empty tag
- </p>
- 2
- True
- 100
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids