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 heading shows the BIGGEST text: <h4>, <h3>, <h6> or <h1>? (a) <h4> (b) <h3> (c) <h1> (d) <h6>
- 2.📝 Does <li> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
3.🔗 Where does this link open?
<a href="games.html" target="_blank">About us</a> (a) in the same tab (b) in a new tab - 4.💬 Does the browser show comments on the page? (a) No (b) Yes
- 5.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <ol> (c) <br> (d) <hr>
- 6.🔗 Which code links to about.html? (a) <a href="about.html"> (b) <link about.html> (c) <a src="about.html"> (d) <a alt="about.html">
- 7.True or false: in <img>, alt names the picture file. (a) True (b) False
- 8.💾 A web page file usually ends with which extension? (a) .txt (b) .html (c) .mp3 (d) .png
- 9.🔠 Which heading shows the BIGGEST text: <h2>, <h6>, <h4> or <h5>? (a) <h6> (b) <h5> (c) <h4> (d) <h2>
- 10.True or false: in <img>, src tells which image to load. (a) False (b) True
-
11.💬 How many paragraphs show on the page?
<!-- <p>My pets</p> -->
<!-- <p>Cricket is fun.</p> -->
<p>My best friend</p> - 12.📄 Can HTML on its own count button clicks? (a) Yes (b) No
-
13.📝 How many paragraphs does this code make?
<p>Good morning!</p>
<p>Good morning!</p>
<p>I love mangoes.</p>
<p>The red kite</p> -
14.💬 Which text will NOT show on the page?
<!-- <p>Fun facts</p> -->
<p>My pets</p>
<p>Hello, world!</p> (a) Hello, world! (b) Fun facts (c) My pets - 15.📝 What does <p> make? (a) a table (b) a link (c) a picture (d) a paragraph
-
16.🔠 How many headings are in this code?
<h1>Cricket is fun.</h1>
<h2>The red kite</h2>
<p>Fun facts</p>
<h4>Our school trip</h4> -
17.📋 How many items does this list show?
<ol>
<li>Banana</li>
<li>Guava</li>
<li>Grapes</li>
<li>Papaya</li>
</ol> - 18.🏷️ Which is the closing tag for <u>? (a) <u> (b) <u/> (c) <\u> (d) </u>
-
19.💬 Which text will NOT show on the page?
<!-- <p>My pets</p> -->
<p>Hello, world!</p>
<p>Our school trip</p> (a) My pets (b) Our school trip (c) Hello, world! -
20.📝 How many paragraphs does this code make?
<p>Good morning!</p>
<p>My pets</p>
<h2>Rain today</h2>
<h2>Rain today</h2>
<p>Good morning!</p>
<p>Hello, world!</p> - 21.Which of these is true of a code editor? (a) is where we type code (b) answers page requests (c) sends pages over the net (d) has an address bar
-
22.🔍 One closing tag is missing. Which one?
<b>Our school trip
<i>Fun facts</i>
<h1>My pets</h1> (a) </small> (b) </i> (c) </h1> (d) </b> - 23.📝 Does <input> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 24.True or false: a web server answers page requests. (a) False (b) True
- 25.True or false: HTML on its own can add up two numbers. (a) False (b) True
- 26.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
- 27.📋 Which list suits a shopping list in any order? (a) <ol> (b) <hr> (c) <br> (d) <ul>
-
28.📋 How many items does this list show?
<ol>
<li>Guava</li>
<li>Jamun</li>
<li>Orange</li>
<li>Litchi</li>
</ol> - 29.Which of these goes in the head? (a) <p> (b) <style> (c) <table> (d) <img>
-
30.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="400"> - 31.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 32.🧩 An opening tag + content + a closing tag together make an ___. (a) address (b) attribute (c) editor (d) element
-
33.🔍 One closing tag is missing. Which one?
<h2>Hello, world!
<i>Good morning!</i>
<h3>The red kite</h3> (a) </h3> (b) </h2> (c) </i> (d) </strong> - 34.📋 Which list tag shows 1, 2, 3 numbers? (a) <li> (b) <ul> (c) <ol>
- 35.📝 Does <hr> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 36.🔠 Which heading shows the SMALLEST text: <h1>, <h6>, <h4> or <h3>? (a) <h4> (b) <h1> (c) <h3> (d) <h6>
- 37.Which of these goes in the head? (a) <table> (b) <ul> (c) <h1> (d) <title>
- 38.True or false: <img> goes in the head. (a) True (b) False
- 39.True or false: <a> goes in the head. (a) True (b) False
-
40.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Sky is blue<br>Kites fly high<br>Stars shine<br>Birds sing</p>
Answer key
- <h1>
- has a closing tag
- in a new tab
- No
- <ol>
- <a href="about.html">
- False
- .html
- <h2>
- True
- 1
- No
- 4
- Fun facts
- a paragraph
- 3
- 4
- </u>
- My pets
- 4
- is where we type code
- </b>
- an empty tag
- True
- False
- Yes
- <ul>
- 4
- <style>
- 400
- No
- element
- </h2>
- <ol>
- an empty tag
- <h6>
- <title>
- False
- False
- 5
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids