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 words do you click on?
<a href="news.html">Visit the site</a> (a) href (b) Visit the site (c) Maths fun (d) news.html - 2.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
3.🔗 Which words do you click on?
<a href="art.html">Contact us</a> (a) Visit the site (b) art.html (c) href (d) Contact us - 4.🏷️ Which is the closing tag for <h2>? (a) <\h2> (b) <h2> (c) <h2/> (d) </h2>
-
5.🔗 Which words do you click on?
<a href="about.html">Maths fun</a> (a) about.html (b) Art corner (c) Maths fun (d) href - 6.🔠 Which heading shows the BIGGEST text: <h3>, <h1>, <h5> or <h2>? (a) <h3> (b) <h1> (c) <h2> (d) <h5>
- 7.🔠 How many heading levels does HTML have? (a) 10 (b) 4 (c) 6 (d) 3
- 8.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
- 9.🔍 Which is the odd one out? (a) has an address bar (b) shows pages from the web (c) turns HTML into a page (d) shows line numbers
-
10.🔗 Where does this link open?
<a href="games.html" target="_blank">Play games</a> (a) in the same tab (b) in a new tab -
11.🔗 Where does this link open?
<a href="quiz.html">Visit the site</a> (a) in the same tab (b) in a new tab -
12.📋 What number does the browser show next to “Guava”?
<ol start="6">
<li>Mango</li>
<li>Guava</li>
<li>Litchi</li>
</ol> -
13.🔍 Which line is missing its closing tag?
line 1: <small>Our school trip</small>
line 2: <p>My best friend
line 3: <u>Rain today</u> (a) line 3 (b) line 1 (c) line 2 -
14.📋 What number does the browser show next to “Litchi”?
<ol start="4">
<li>Grapes</li>
<li>Litchi</li>
<li>Guava</li>
<li>Papaya</li>
</ol> - 15.🔗 Which code links to about.html? (a) <a alt="about.html"> (b) <a src="about.html"> (c) <a href="about.html"> (d) <link about.html>
- 16.🔠 Which tag is used for the main title on a page? (a) <h1> (b) <p> (c) <h6> (d) <br>
- 17.🔍 Which is the odd one out? (a) has an address bar (b) stores a website’s files (c) turns HTML into a page (d) opens web pages for us
- 18.💬 How does an HTML comment start? (a) # (b) /* (c) <!-- (d) //
- 19.🔠 Which heading shows the SMALLEST text: <h2>, <h1>, <h5> or <h6>? (a) <h5> (b) <h6> (c) <h1> (d) <h2>
- 20.Which of these is an opening tag? (a) </body> (b) </li> (c) </b> (d) <body>
-
21.🔗 Which words do you click on?
<a href="maths.html">Maths fun</a> (a) Art corner (b) maths.html (c) href (d) Maths fun -
22.🔠 How many headings are in this code?
<h1>Cricket is fun.</h1>
<h4>My pets</h4>
<h3>The red kite</h3> - 23.🔠 Which heading shows the BIGGEST text: <h1>, <h3>, <h5> or <h4>? (a) <h3> (b) <h1> (c) <h5> (d) <h4>
-
24.📝 How many paragraphs does this code make?
<p>Hello, world!</p>
<p>Hello, world!</p>
<p>Hello, world!</p> -
25.📋 How many items does this list show?
<ol>
<li>Litchi</li>
<li>Jamun</li>
<li>Mango</li>
</ol> - 26.📄 Which part holds everything you see on the page? (a) the body (b) the head (c) the doctype (d) the title
- 27.Which of these is an opening tag? (a) <p> (b) </p> (c) </li> (d) </body>
-
28.📝 On how many lines does the browser show this paragraph?
<p>Sky is blue<br>Stars shine<br>Kites fly high<br>Roses are red<br>Birds sing</p> -
29.🔗 Where does this link open?
<a href="games.html">Visit the site</a> (a) in a new tab (b) in the same tab - 30.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ol> (c) <ul> (d) <br>
-
31.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>Fun facts</p>
<p>The red kite</p> - 32.💬 Why do coders write comments? (a) to show pictures (b) to make links (c) to leave notes (d) to add colour
-
33.🔗 Which words do you click on?
<a href="maths.html">Contact us</a> (a) Visit the site (b) href (c) Contact us (d) maths.html - 34.📄 Can HTML on its own add up two numbers? (a) Yes (b) No
- 35.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
- 36.🔠 Which heading shows the BIGGEST text: <h5>, <h1>, <h3> or <h4>? (a) <h3> (b) <h4> (c) <h5> (d) <h1>
- 37.🖼️ Why do we add alt text to an image? (a) to load it faster (b) to describe the image (c) to make it bigger (d) to colour it
- 38.🔠 Are headings shown in bold by default? (a) No (b) Yes
-
39.🔠 How many headings are in this code?
<h1>My best friend</h1>
<p>Our school trip</p>
<p>Our school trip</p> - 40.True or false: a web server sends pages over the net. (a) True (b) False
Answer key
- Visit the site
- an opening tag
- Contact us
- </h2>
- Maths fun
- <h1>
- 6
- <ul>
- shows line numbers
- in a new tab
- in the same tab
- 7
- line 2
- 5
- <a href="about.html">
- <h1>
- stores a website’s files
- <!--
- <h6>
- <body>
- Maths fun
- 3
- <h1>
- 3
- 3
- the body
- <p>
- 5
- in the same tab
- <ul>
- 2
- to leave notes
- Contact us
- No
- Yes
- <h1>
- to describe the image
- Yes
- 1
- True
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids