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 of these is true of a web browser? (a) saves our .html files (b) hosts websites online (c) answers page requests (d) turns HTML into a page
- 2.📄 Can HTML on its own add up two numbers? (a) No (b) Yes
-
3.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Rivers flow</p> -
4.🔗 Which words do you click on?
<a href="about.html">About us</a> (a) About us (b) about.html (c) Contact us (d) href -
5.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<h2>I love mangoes.</h2>
<h4>My pets</h4>
<h3>Good morning!</h3> - 6.🖼️ Why do we add alt text to an image? (a) to describe the image (b) to colour it (c) to make it bigger (d) to load it faster
-
7.📋 Does this list show bullets or numbers?
<ol>
<li>Banana</li>
<li>Grapes</li>
<li>Litchi</li>
</ol> (a) bullets (b) numbers - 8.📄 Where does <meta charset="utf-8"> go: in the head or in the body? (a) in the head (b) in the body
-
9.📋 How many items does this list show?
<ul>
<li>Mango</li>
<li>Grapes</li>
</ul> -
10.🔍 One closing tag is missing. Which one?
<h1>My pets</h1>
<h3>Hello, world!</h3>
<h2>Our school trip (a) </h2> (b) </p> (c) </h1> (d) </h3> - 11.🌐 Which one sends pages over the net? (a) a code editor (b) a web browser (c) a web server
-
12.🔠 How many headings are in this code?
<h1>My best friend</h1>
<p>Cricket is fun.</p>
<h4>Good morning!</h4> - 13.📝 Does <b> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 14.💬 Does the browser show comments on the page? (a) Yes (b) No
-
15.💬 How many paragraphs show on the page?
<p>Our school trip</p>
<!-- <p>My best friend</p> -->
<p>My pets</p> -
16.🔍 One closing tag is missing. Which one?
<h2>Hello, world!
<small>The red kite</small>
<p>I love mangoes.</p> (a) </small> (b) </p> (c) </h2> (d) </h1> - 17.📝 What does <br> do? (a) makes a list (b) adds a picture (c) starts a new line (d) makes text bold
- 18.🔗 Which attribute holds the address of a link? (a) src (b) alt (c) id (d) href
-
19.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<!-- <p>Fun facts</p> -->
<p>Cricket is fun.</p>
<!-- <p>My pets</p> -->
<!-- <p>Our school trip</p> --> -
20.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<p>My pets</p>
<p>Cricket is fun.</p>
<p>Rain today</p> - 21.🔍 Which is the odd one out? (a) turns HTML into a page (b) opens web pages for us (c) has an address bar (d) shows line numbers
- 22.📋 Which list tag shows bullet points? (a) <li> (b) <ol> (c) <ul>
-
23.🔠 How many headings are in this code?
<h1>Cricket is fun.</h1>
<h4>Rain today</h4>
<h4>My pets</h4> -
24.📝 How many paragraphs does this code make?
<p>Fun facts</p>
<p>My pets</p>
<h2>Hello, world!</h2>
<p>I love mangoes.</p>
<p>Cricket is fun.</p> - 25.🔠 Which heading shows the BIGGEST text: <h4>, <h1>, <h2> or <h6>? (a) <h2> (b) <h1> (c) <h6> (d) <h4>
-
26.🔗 Which words do you click on?
<a href="quiz.html">Maths fun</a> (a) href (b) Maths fun (c) Art corner (d) quiz.html -
27.💬 How many paragraphs show on the page?
<!-- <p>Rain today</p> -->
<p>Cricket is fun.</p>
<p>My best friend</p>
<!-- <p>The red kite</p> -->
<p>I love mangoes.</p> - 28.📄 Which part holds everything you see on the page? (a) the doctype (b) the body (c) the head (d) the title
- 29.📛 In <a href="x.html">, what is href? (a) a comment (b) an attribute (c) a closing tag (d) an element name
- 30.🖼️ Which attribute of <img> names the picture file? (a) alt (b) width (c) src (d) height
-
31.💬 Which text will NOT show on the page?
<p>Hello, world!</p>
<!-- <p>Cricket is fun.</p> -->
<p>My best friend</p>
<p>Fun facts</p> (a) Hello, world! (b) Cricket is fun. (c) Fun facts (d) My best friend - 32.Which of these is true of a code editor? (a) hosts websites online (b) turns HTML into a page (c) shows line numbers (d) stores a website’s files
-
33.🔗 Which address opens when you click this link?
<a href="contact.html">Play games</a> (a) contact.html (b) Play games (c) https://example.com (d) maths.html - 34.🏷️ Which is the closing tag for <em>? (a) </em> (b) <\em> (c) <em/> (d) <em>
-
35.🖼️ Which picture file does the browser load?
<img src="moon.png" alt="The full moon" width="250"> (a) The full moon (b) bus.jpg (c) moon.png (d) fort.jpg -
36.📋 How many items does this list show?
<ol>
<li>Grapes</li>
<li>Jamun</li>
<li>Banana</li>
<li>Guava</li>
<li>Litchi</li>
<li>Papaya</li>
</ol> - 37.Which of these is true of a web server? (a) saves our .html files (b) has an address bar (c) opens web pages for us (d) stores a website’s files
-
38.📋 Does this list show bullets or numbers?
<ol>
<li>Guava</li>
<li>Mango</li>
<li>Papaya</li>
</ol> (a) numbers (b) bullets - 39.🔠 Which heading shows the SMALLEST text: <h5>, <h1>, <h6> or <h4>? (a) <h5> (b) <h1> (c) <h4> (d) <h6>
-
40.🔗 Which address opens when you click this link?
<a href="https://example.com">Play games</a> (a) Play games (b) art.html (c) maths.html (d) https://example.com
Answer key
- turns HTML into a page
- No
- 2
- About us
- 4
- to describe the image
- numbers
- in the head
- 2
- </h2>
- a web server
- 2
- has a closing tag
- No
- 2
- </h2>
- starts a new line
- href
- 1
- 3
- shows line numbers
- <ul>
- 3
- 4
- <h1>
- Maths fun
- 3
- the body
- an attribute
- src
- Cricket is fun.
- shows line numbers
- contact.html
- </em>
- moon.png
- 6
- stores a website’s files
- numbers
- <h6>
- https://example.com
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids