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 code links to about.html? (a) <a href="about.html"> (b) <a src="about.html"> (c) <a alt="about.html"> (d) <link about.html>
-
2.📋 Does this list show bullets or numbers?
<ul>
<li>Mango</li>
<li>Guava</li>
<li>Orange</li>
</ul> (a) numbers (b) bullets - 3.🌐 Which one is where we type code? (a) a web browser (b) a web server (c) a code editor
- 4.True or false: in <img>, height is read by screen readers. (a) True (b) False
- 5.📝 Does <img> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
-
6.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<!-- <p>The red kite</p> -->
<!-- <p>Rain today</p> -->
<!-- <p>Fun facts</p> --> -
7.🖼️ Which picture file does the browser load?
<img src="dog.jpg" alt="A happy dog" width="150"> (a) bus.jpg (b) dog.jpg (c) moon.png (d) A happy dog - 8.🔠 Which tag is the least important heading? (a) <p> (b) <h3> (c) <h1> (d) <h6>
-
9.💬 How many paragraphs show on the page?
<p>Rain today</p>
<!-- <p>My pets</p> -->
<p>The red kite</p>
<p>Our school trip</p>
<p>My best friend</p> -
10.🔗 Where does this link open?
<a href="news.html" target="_blank">School news</a> (a) in a new tab (b) in the same tab - 11.Which of these is true of a web browser? (a) saves our .html files (b) has an address bar (c) is where we type code (d) shows line numbers
- 12.True or false: a code editor shows pages from the web. (a) False (b) True
- 13.📋 Which tag goes around each item of a list? (a) <li> (b) <p> (c) <ol> (d) <ul>
- 14.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h1> or <h2>? (a) <h6> (b) <h3> (c) <h2> (d) <h1>
-
15.🔗 Which address opens when you click this link?
<a href="https://example.com">Art corner</a> (a) maths.html (b) https://example.com (c) art.html (d) Art corner -
16.🔍 Which line is missing its closing tag?
line 1: <strong>Fun facts</strong>
line 2: <u>Hello, world!</u>
line 3: <h2>Good morning! (a) line 1 (b) line 2 (c) line 3 - 17.🔠 How many heading levels does HTML have? (a) 10 (b) 4 (c) 3 (d) 6
- 18.True or false: <h1> has a closing tag. (a) False (b) True
- 19.📝 What do we need to write HTML? (a) a plain text editor (b) a microphone (c) a paintbrush (d) a printer
-
20.🔗 Where does this link open?
<a href="quiz.html" target="_blank">Maths fun</a> (a) in the same tab (b) in a new tab -
21.📋 What number does the browser show next to “Guava”?
<ol start="4">
<li>Orange</li>
<li>Jamun</li>
<li>Litchi</li>
<li>Guava</li>
<li>Banana</li>
<li>Grapes</li>
</ol> -
22.🔗 Which words do you click on?
<a href="about.html">Play games</a> (a) about.html (b) About us (c) href (d) Play games - 23.True or false: <ol> shows 1, 2, 3 numbers. (a) False (b) True
- 24.🔗 Which tag makes a clickable link? (a) <img> (b) <link> (c) <p> (d) <a>
- 25.🔗 Which attribute holds the address of a link? (a) href (b) src (c) id (d) alt
-
26.🔗 Where does this link open?
<a href="news.html">Visit the site</a> (a) in the same tab (b) in a new tab - 27.🏷️ Is <b> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
28.🔗 Which address opens when you click this link?
<a href="games.html">Take the quiz</a> (a) contact.html (b) about.html (c) Take the quiz (d) games.html - 29.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as 5 spaces (b) as a new line (c) as a dot (d) as one space
-
30.💬 Which text will NOT show on the page?
<!-- <p>Cricket is fun.</p> -->
<p>My pets</p>
<p>My best friend</p>
<p>Fun facts</p> (a) My best friend (b) Fun facts (c) My pets (d) Cricket is fun. -
31.🖼️ How many pixels wide is the picture drawn?
<img src="map.png" alt="Map of India" width="100"> - 32.🔠 How many <h1> headings should a page usually have? (a) 10 (b) 6 (c) 1 (d) 3
-
33.🔠 How many headings are in this code?
<h1>The red kite</h1>
<h4>Hello, world!</h4>
<h2>Cricket is fun.</h2>
<p>My pets</p>
<p>The red kite</p> -
34.📝 On how many lines does the browser show this paragraph?
<p>Kites fly high<br>Stars shine<br>Birds sing</p> - 35.📄 Where does <p> go: in the head or in the body? (a) in the body (b) in the head
-
36.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Class 7 Blog</title>
</head>
<body>
<h1>Welcome!</h1>
<p>Thanks for visiting.</p>
</body>
</html> (a) Welcome! (b) Class 7 Blog (c) body (d) Thanks for visiting. - 37.Which of these is true of a code editor? (a) has an address bar (b) saves our .html files (c) turns HTML into a page (d) shows pages from the web
- 38.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <ol> (d) <br>
- 39.🌐 Which one has an address bar? (a) a web browser (b) a code editor (c) a web server
-
40.🔗 Which words do you click on?
<a href="quiz.html">Art corner</a> (a) Art corner (b) href (c) quiz.html (d) School news
Answer key
- <a href="about.html">
- bullets
- a code editor
- False
- an empty tag
- 1
- dog.jpg
- <h6>
- 4
- in a new tab
- has an address bar
- False
- <li>
- <h1>
- https://example.com
- line 3
- 6
- True
- a plain text editor
- in a new tab
- 7
- Play games
- True
- <a>
- href
- in the same tab
- an opening tag
- games.html
- as one space
- Cricket is fun.
- 100
- 1
- 3
- 3
- in the body
- Welcome!
- saves our .html files
- <ul>
- a web browser
- Art corner
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids