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 one colours code to help us? (a) a web browser (b) a code editor (c) a web server
-
2.🔍 Which line is missing its closing tag?
line 1: <h1>Good morning!</h1>
line 2: <u>Cricket is fun.
line 3: <b>I love mangoes.</b> (a) line 3 (b) line 2 (c) line 1 - 3.🔠 Which heading shows the SMALLEST text: <h6>, <h4>, <h1> or <h3>? (a) <h1> (b) <h4> (c) <h3> (d) <h6>
-
4.📝 How many paragraphs does this code make?
<p>The red kite</p>
<h2>The red kite</h2>
<p>Cricket is fun.</p> -
5.📋 How many items does this list show?
<ul>
<li>Papaya</li>
<li>Litchi</li>
<li>Jamun</li>
<li>Banana</li>
<li>Orange</li>
<li>Mango</li>
</ul> - 6.📋 Which list tag is an ordered list? (a) <li> (b) <ol> (c) <ul>
-
7.🔗 Where does this link open?
<a href="news.html">Visit the site</a> (a) in a new tab (b) in the same tab - 8.🌍 Which program shows a web page to us? (a) a web browser (b) a music player (c) a calculator (d) a paint program
- 9.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h5> or <h1>? (a) <h2> (b) <h5> (c) <h3> (d) <h1>
- 10.🌐 Which one has an address bar? (a) a code editor (b) a web browser (c) a web server
- 11.📝 What does <br> do? (a) makes text bold (b) adds a picture (c) starts a new line (d) makes a list
- 12.📝 Does <img> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 13.🖼️ Which attribute of <img> names the picture file? (a) height (b) width (c) src (d) alt
- 14.Which of these is an empty tag? (a) <li> (b) <b> (c) <ul> (d) <br>
-
15.🔗 Which words do you click on?
<a href="maths.html">Art corner</a> (a) maths.html (b) School news (c) href (d) Art corner - 16.Which of these is a closing tag? (a) </h1> (b) <title> (c) <h1> (d) <p>
- 17.🔢 In a basic web page file, which comes FIRST? (a) <!DOCTYPE html> (b) <body> (c) <head> (d) </html>
-
18.🔍 One closing tag is missing. Which one?
<u>My pets</u>
<b>My best friend</b>
<p>Hello, world! (a) </h3> (b) </b> (c) </p> (d) </u> -
19.💬 Which text will NOT show on the page?
<p>Our school trip</p>
<!-- <p>Fun facts</p> -->
<p>Rain today</p>
<p>Hello, world!</p> (a) Our school trip (b) Hello, world! (c) Fun facts (d) Rain today -
20.🔍 One closing tag is missing. Which one?
<strong>My pets</strong>
<b>I love mangoes.</b>
<em>Hello, world! (a) </b> (b) </i> (c) </strong> (d) </em> - 21.🔠 Which heading shows the SMALLEST text: <h5>, <h6>, <h1> or <h3>? (a) <h5> (b) <h6> (c) <h3> (d) <h1>
-
22.🔗 Which words do you click on?
<a href="games.html">Contact us</a> (a) games.html (b) Visit the site (c) href (d) Contact us - 23.True or false: <img> goes in the body. (a) False (b) True
- 24.🔢 In a basic web page file, which comes LAST? (a) <!DOCTYPE html> (b) </body> (c) <html> (d) </html>
-
25.📄 What does the browser tab show for this page?
<!DOCTYPE html>
<html>
<head>
<title>Riya’s Recipes</title>
</head>
<body>
<h1>My drawings</h1>
<p>I like to read.</p>
</body>
</html> (a) I like to read. (b) Riya’s Recipes (c) index.html (d) My drawings - 26.Which of these is true of a web browser? (a) colours code to help us (b) opens web pages for us (c) shows line numbers (d) answers page requests
- 27.📛 In <a href="x.html">, what is href? (a) a closing tag (b) an element name (c) a comment (d) an attribute
- 28.True or false: HTML on its own can make headings. (a) False (b) True
-
29.💬 Which text will NOT show on the page?
<!-- <p>I love mangoes.</p> -->
<p>Fun facts</p>
<p>Our school trip</p>
<p>The red kite</p> (a) I love mangoes. (b) Fun facts (c) The red kite (d) Our school trip - 30.🔠 Which heading shows the BIGGEST text: <h2>, <h3>, <h4> or <h1>? (a) <h4> (b) <h2> (c) <h3> (d) <h1>
- 31.🔠 Which heading shows the SMALLEST text: <h4>, <h2>, <h6> or <h5>? (a) <h2> (b) <h6> (c) <h4> (d) <h5>
- 32.🧩 An opening tag + content + a closing tag together make an ___. (a) attribute (b) address (c) editor (d) element
- 33.True or false: HTML on its own cannot count button clicks. (a) False (b) True
- 34.🔠 Which heading shows the BIGGEST text: <h5>, <h3>, <h1> or <h2>? (a) <h2> (b) <h3> (c) <h5> (d) <h1>
- 35.🏷️ Which is the closing tag for <em>? (a) <em> (b) <em/> (c) </em> (d) <\em>
- 36.🏷️ Every HTML tag starts with which sign? (a) { (b) [ (c) ( (d) <
-
37.🔍 One closing tag is missing. Which one?
<strong>Good morning!
<p>My best friend</p>
<i>Cricket is fun.</i> (a) </i> (b) </p> (c) </strong> (d) </h3> - 38.🔍 Which is the odd one out? (a) stores a website’s files (b) sends pages over the net (c) answers page requests (d) is where we type code
- 39.🌐 Which one stores a website’s files? (a) a web browser (b) a code editor (c) a web server
- 40.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
Answer key
- a code editor
- line 2
- <h6>
- 2
- 6
- <ol>
- in the same tab
- a web browser
- <h1>
- a web browser
- starts a new line
- an empty tag
- src
- <br>
- Art corner
- </h1>
- <!DOCTYPE html>
- </p>
- Fun facts
- </em>
- <h6>
- Contact us
- True
- </html>
- Riya’s Recipes
- opens web pages for us
- an attribute
- True
- I love mangoes.
- <h1>
- <h6>
- element
- True
- <h1>
- </em>
- <
- </strong>
- is where we type code
- a web server
- an opening tag
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids