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">Art corner</a> (a) in a new tab (b) in the same tab - 2.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <hr> (c) <br> (d) <ol>
- 3.🔠 How many <h1> headings should a page usually have? (a) 3 (b) 6 (c) 10 (d) 1
- 4.📄 Where does the text of <title> appear? (a) at the bottom (b) nowhere (c) on the browser tab (d) in a big heading
- 5.💬 Why do coders write comments? (a) to make links (b) to show pictures (c) to add colour (d) to leave notes
- 6.True or false: a code editor saves our .html files. (a) False (b) True
- 7.🖼️ Why do we add alt text to an image? (a) to colour it (b) to load it faster (c) to describe the image (d) to make it bigger
- 8.🧩 An opening tag + content + a closing tag together make an ___. (a) editor (b) attribute (c) address (d) element
-
9.🔗 Which words do you click on?
<a href="news.html">Maths fun</a> (a) Art corner (b) href (c) news.html (d) Maths fun -
10.🖼️ Which picture file does the browser load?
<img src="dog.jpg" alt="A happy dog" width="200"> (a) bus.jpg (b) moon.png (c) dog.jpg (d) A happy dog -
11.💬 How many paragraphs show on the page?
<p>Cricket is fun.</p>
<p>Fun facts</p>
<!-- <p>Hello, world!</p> -->
<!-- <p>Our school trip</p> --> - 12.True or false: <ul> shows 1, 2, 3 numbers. (a) False (b) True
-
13.🔗 Which address opens when you click this link?
<a href="contact.html">School news</a> (a) contact.html (b) https://example.com (c) School news (d) maths.html -
14.🖼️ Which picture file does the browser load?
<img src="bus.jpg" alt="Our school bus" width="50"> (a) Our school bus (b) fort.jpg (c) bus.jpg (d) tiger.jpg - 15.Which of these is true of a code editor? (a) hosts websites online (b) has an address bar (c) is where we type code (d) opens web pages for us
-
16.💬 How many paragraphs show on the page?
<!-- <p>Hello, world!</p> -->
<!-- <p>I love mangoes.</p> -->
<p>Cricket is fun.</p> - 17.🔠 Which heading shows the BIGGEST text: <h3>, <h1>, <h2> or <h6>? (a) <h6> (b) <h3> (c) <h1> (d) <h2>
-
18.🔗 Where does this link open?
<a href="about.html">Contact us</a> (a) in a new tab (b) in the same tab - 19.🔠 How many heading levels does HTML have? (a) 3 (b) 6 (c) 10 (d) 4
- 20.🌐 Which one stores a website’s files? (a) a web browser (b) a code editor (c) a web server
- 21.🏷️ Which is the closing tag for <em>? (a) </em> (b) <em> (c) <em/> (d) <\em>
-
22.📋 How many items does this list show?
<ol>
<li>Grapes</li>
<li>Guava</li>
<li>Banana</li>
<li>Orange</li>
<li>Litchi</li>
</ol> -
23.🔍 One closing tag is missing. Which one?
<h2>The red kite
<strong>Hello, world!</strong>
<u>Our school trip</u> (a) </u> (b) </strong> (c) </small> (d) </h2> - 24.🖼️ Which attribute of <img> is read by screen readers? (a) src (b) alt (c) height (d) width
- 25.🏷️ Which is the closing tag for <i>? (a) </i> (b) <i/> (c) <i> (d) <\i>
-
26.🔗 Where does this link open?
<a href="news.html" target="_blank">School news</a> (a) in a new tab (b) in the same tab -
27.💬 How many paragraphs show on the page?
<!-- <p>Rain today</p> -->
<!-- <p>Cricket is fun.</p> -->
<p>The red kite</p> - 28.True or false: HTML on its own cannot run a game loop. (a) True (b) False
- 29.🔍 Which is the odd one out? (a) has an address bar (b) answers page requests (c) shows pages from the web (d) turns HTML into a page
- 30.🖼️ Which attribute of <img> names the picture file? (a) src (b) height (c) width (d) alt
-
31.🔗 Where does this link open?
<a href="https://example.com" target="_blank">Contact us</a> (a) in the same tab (b) in a new tab - 32.🔠 Which heading shows the SMALLEST text: <h1>, <h3>, <h6> or <h2>? (a) <h2> (b) <h3> (c) <h1> (d) <h6>
-
33.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<!-- <p>Hello, world!</p> -->
<p>My best friend</p>
<p>Our school trip</p>
<p>Rain today</p> - 34.🔍 Which is the odd one out? (a) colours code to help us (b) is where we type code (c) shows line numbers (d) opens web pages for us
-
35.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="300"> (a) A red kite (b) cake.jpg (c) map.png (d) kite.png - 36.🌐 Which one has an address bar? (a) a web server (b) a web browser (c) a code editor
- 37.Which of these is an opening tag? (a) </b> (b) </h1> (c) </body> (d) <title>
- 38.🏷️ Is </h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
39.💬 How many paragraphs show on the page?
<p>My pets</p>
<!-- <p>Hello, world!</p> -->
<p>The red kite</p>
<p>Our school trip</p> -
40.🔗 Which address opens when you click this link?
<a href="news.html">Maths fun</a> (a) news.html (b) games.html (c) Maths fun (d) quiz.html
Answer key
- in a new tab
- <ol>
- 1
- on the browser tab
- to leave notes
- True
- to describe the image
- element
- Maths fun
- dog.jpg
- 2
- False
- contact.html
- bus.jpg
- is where we type code
- 1
- <h1>
- in the same tab
- 6
- a web server
- </em>
- 5
- </h2>
- alt
- </i>
- in a new tab
- 1
- True
- answers page requests
- src
- in a new tab
- <h6>
- 4
- opens web pages for us
- kite.png
- a web browser
- <title>
- a closing tag
- 3
- news.html
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids