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.🔗 Where does this link open?
<a href="https://example.com" target="_blank">About us</a> (a) in the same tab (b) in a new tab -
2.📋 Does this list show bullets or numbers?
<ol>
<li>Litchi</li>
<li>Orange</li>
<li>Jamun</li>
</ol> (a) bullets (b) numbers -
3.📋 How many items does this list show?
<ol>
<li>Mango</li>
<li>Litchi</li>
</ol> - 4.Which of these goes in the head? (a) <a> (b) <title> (c) <img> (d) <h1>
- 5.🏷️ What does a closing tag have that an opening tag does not? (a) a dollar $ (b) a slash / (c) a hash # (d) a dot .
-
6.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<!-- <p>My pets</p> -->
<p>Good morning!</p>
<p>My best friend</p>
<p>I love mangoes.</p> - 7.Which of these goes in the head? (a) <ul> (b) <meta charset="utf-8"> (c) <a> (d) <p>
-
8.📋 Does this list show bullets or numbers?
<ol>
<li>Grapes</li>
<li>Papaya</li>
</ol> (a) bullets (b) numbers -
9.📋 What number does the browser show next to “Jamun”?
<ol>
<li>Litchi</li>
<li>Jamun</li>
<li>Mango</li>
<li>Grapes</li>
</ol> - 10.True or false: in <img>, width tells which image to load. (a) True (b) False
- 11.True or false: in <img>, height sets how tall it is. (a) False (b) True
- 12.Which of these is a closing tag? (a) <b> (b) </title> (c) <p> (d) <h1>
-
13.📋 What number does the browser show next to “Banana”?
<ol start="8">
<li>Grapes</li>
<li>Orange</li>
<li>Guava</li>
<li>Banana</li>
<li>Papaya</li>
</ol> - 14.📛 In <a href="x.html">, what is href? (a) an element name (b) a comment (c) a closing tag (d) an attribute
-
15.💬 Which text will NOT show on the page?
<p>Cricket is fun.</p>
<p>My best friend</p>
<!-- <p>I love mangoes.</p> --> (a) I love mangoes. (b) My best friend (c) Cricket is fun. - 16.🔗 What does target="_blank" do to a link? (a) opens it in a new tab (b) hides the link (c) makes it bold (d) makes it blank
-
17.🔗 Which address opens when you click this link?
<a href="games.html">Contact us</a> (a) Contact us (b) games.html (c) about.html (d) contact.html -
18.🖼️ How many pixels wide is the picture drawn?
<img src="dog.jpg" alt="A happy dog" width="400"> - 19.Which of these goes in the body? (a) <style> (b) <meta charset="utf-8"> (c) <p> (d) <link rel="stylesheet">
- 20.🔗 Which tag makes a clickable link? (a) <img> (b) <link> (c) <a> (d) <p>
- 21.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
- 22.🔠 Which heading shows the SMALLEST text: <h1>, <h5>, <h6> or <h3>? (a) <h5> (b) <h6> (c) <h3> (d) <h1>
- 23.📄 Which part holds everything you see on the page? (a) the body (b) the title (c) the doctype (d) the head
-
24.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="bus.jpg" alt="Our school bus" width="350"> (a) Our school bus (b) bus.jpg (c) width (d) An old fort -
25.🔗 Where does this link open?
<a href="maths.html">Take the quiz</a> (a) in the same tab (b) in a new tab - 26.Which of these goes in the body? (a) <a> (b) <link rel="stylesheet"> (c) <style> (d) <title>
- 27.Which of these is true of a code editor? (a) stores a website’s files (b) is where we type code (c) hosts websites online (d) turns HTML into a page
-
28.📝 On how many lines does the browser show this paragraph?
<p>Kites fly high<br>Rivers flow<br>Stars shine</p> - 29.True or false: <table> goes in the body. (a) True (b) False
- 30.🏷️ Which is the closing tag for <p>? (a) <p/> (b) <\p> (c) <p> (d) </p>
-
31.🔗 Which address opens when you click this link?
<a href="news.html">School news</a> (a) quiz.html (b) games.html (c) news.html (d) School news -
32.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Rivers flow</p> - 33.🏷️ Is <p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 34.🔗 Which code links to about.html? (a) <a alt="about.html"> (b) <a src="about.html"> (c) <a href="about.html"> (d) <link about.html>
- 35.Which of these is true of a web server? (a) opens web pages for us (b) saves our .html files (c) shows line numbers (d) answers page requests
-
36.🔍 One closing tag is missing. Which one?
<strong>My pets
<p>Our school trip</p>
<b>Rain today</b> (a) </strong> (b) </i> (c) </p> (d) </b> - 37.🏷️ Is </li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 38.📄 Can HTML on its own make headings? (a) Yes (b) No
- 39.True or false: HTML on its own can keep a high score. (a) False (b) True
- 40.Which of these is an opening tag? (a) </title> (b) <p> (c) </b> (d) </h1>
Answer key
- in a new tab
- numbers
- 2
- <title>
- a slash /
- 3
- <meta charset="utf-8">
- numbers
- 2
- False
- True
- </title>
- 11
- an attribute
- I love mangoes.
- opens it in a new tab
- games.html
- 400
- <p>
- <a>
- <ul>
- <h6>
- the body
- Our school bus
- in the same tab
- <a>
- is where we type code
- 3
- True
- </p>
- news.html
- 2
- an opening tag
- <a href="about.html">
- answers page requests
- </strong>
- a closing tag
- Yes
- False
- <p>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids