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.True or false: a web browser shows pages from the web. (a) True (b) False
- 2.🔠 Which heading shows the SMALLEST text: <h1>, <h4>, <h3> or <h5>? (a) <h1> (b) <h3> (c) <h4> (d) <h5>
- 3.Which of these goes in the body? (a) <ul> (b) <link rel="stylesheet"> (c) <title> (d) <style>
-
4.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="150"> (a) A tiger asleep (b) tiger.jpg (c) width (d) A red kite -
5.🔠 How many headings are in this code?
<h1>Fun facts</h1>
<h4>Good morning!</h4>
<p>Our school trip</p> - 6.📋 Which list suits a shopping list in any order? (a) <br> (b) <ol> (c) <hr> (d) <ul>
- 7.📋 Which list tag is an ordered list? (a) <li> (b) <ol> (c) <ul>
- 8.🖼️ Which attribute of <img> is read by screen readers? (a) height (b) alt (c) width (d) src
-
9.💬 How many paragraphs show on the page?
<!-- <p>I love mangoes.</p> -->
<!-- <p>Fun facts</p> -->
<!-- <p>My pets</p> -->
<p>Cricket is fun.</p> - 10.📛 In <a href="x.html">, what is href? (a) a comment (b) a closing tag (c) an attribute (d) an element name
-
11.📋 What number does the browser show next to “Jamun”?
<ol start="3">
<li>Litchi</li>
<li>Jamun</li>
<li>Banana</li>
<li>Guava</li>
<li>Papaya</li>
</ol> -
12.💬 How many paragraphs show on the page?
<p>I love mangoes.</p>
<!-- <p>My pets</p> -->
<!-- <p>Rain today</p> --> -
13.💬 Which text will NOT show on the page?
<p>Cricket is fun.</p>
<p>I love mangoes.</p>
<p>Fun facts</p>
<!-- <p>My pets</p> --> (a) Cricket is fun. (b) Fun facts (c) I love mangoes. (d) My pets - 14.🧩 An opening tag + content + a closing tag together make an ___. (a) address (b) element (c) attribute (d) editor
-
15.📋 Does this list show bullets or numbers?
<ul>
<li>Litchi</li>
<li>Mango</li>
<li>Orange</li>
</ul> (a) numbers (b) bullets - 16.🔗 Which code links to about.html? (a) <link about.html> (b) <a href="about.html"> (c) <a src="about.html"> (d) <a alt="about.html">
- 17.🖼️ Which attribute of <img> tells which image to load? (a) src (b) height (c) alt (d) width
- 18.🔠 Which heading shows the BIGGEST text: <h3>, <h1>, <h4> or <h6>? (a) <h4> (b) <h3> (c) <h1> (d) <h6>
- 19.Which of these is true of a web browser? (a) is where we type code (b) opens web pages for us (c) saves our .html files (d) sends pages over the net
- 20.True or false: <h1> has a closing tag. (a) False (b) True
- 21.🔢 In a basic web page file, which comes FIRST? (a) </html> (b) </body> (c) <!DOCTYPE html> (d) <head>
- 22.🔠 Which heading shows the BIGGEST text: <h3>, <h5>, <h4> or <h1>? (a) <h3> (b) <h5> (c) <h4> (d) <h1>
- 23.💾 A web page file usually ends with which extension? (a) .mp3 (b) .txt (c) .html (d) .png
- 24.True or false: <ul> goes in the body. (a) False (b) True
- 25.🔠 Which heading shows the SMALLEST text: <h5>, <h3>, <h4> or <h1>? (a) <h4> (b) <h3> (c) <h5> (d) <h1>
-
26.💬 How many paragraphs show on the page?
<!-- <p>The red kite</p> -->
<!-- <p>My pets</p> -->
<p>Good morning!</p>
<!-- <p>I love mangoes.</p> --> -
27.🖼️ How many pixels wide is the picture drawn?
<img src="kite.png" alt="A red kite" width="100"> - 28.📝 What does <hr> draw? (a) a picture (b) a table (c) a link (d) a line across the page
- 29.🖼️ Which tag puts a picture on a page? (a) <img> (b) <a> (c) <p> (d) <pic>
-
30.💬 Which text will NOT show on the page?
<p>Good morning!</p>
<p>Our school trip</p>
<!-- <p>I love mangoes.</p> --> (a) Our school trip (b) Good morning! (c) I love mangoes. -
31.📝 How many paragraphs does this code make?
<p>Our school trip</p>
<p>My pets</p>
<p>Good morning!</p> - 32.🔠 Which heading shows the BIGGEST text: <h6>, <h5>, <h3> or <h4>? (a) <h4> (b) <h3> (c) <h5> (d) <h6>
- 33.🌐 Which one colours code to help us? (a) a web browser (b) a code editor (c) a web server
- 34.🔢 In a basic web page file, which comes first: “</html>” or “</body>”? (a) </html> (b) </body>
- 35.📝 Does <h1> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
-
36.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Cricket Club</title>
</head>
<body>
<h1>Planets</h1>
<p>I like to read.</p>
</body>
</html> (a) Cricket Club (b) body (c) Planets (d) I like to read. -
37.💬 How many paragraphs show on the page?
<p>Cricket is fun.</p>
<!-- <p>Good morning!</p> -->
<!-- <p>Fun facts</p> --> - 38.Which of these is true of a code editor? (a) stores a website’s files (b) answers page requests (c) turns HTML into a page (d) is where we type code
-
39.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Roses are red<br>Kites fly high<br>Birds sing<br>Rivers flow</p> - 40.📋 Which list tag shows bullet points? (a) <ul> (b) <li> (c) <ol>
Answer key
- True
- <h5>
- <ul>
- A tiger asleep
- 2
- <ul>
- <ol>
- alt
- 1
- an attribute
- 4
- 1
- My pets
- element
- bullets
- <a href="about.html">
- src
- <h1>
- opens web pages for us
- True
- <!DOCTYPE html>
- <h1>
- .html
- True
- <h5>
- 1
- 100
- a line across the page
- <img>
- I love mangoes.
- 3
- <h3>
- a code editor
- </body>
- has a closing tag
- Planets
- 1
- is where we type code
- 5
- <ul>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids