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.📝 How many paragraphs does this code make?
<p>Rain today</p>
<h2>My pets</h2>
<p>Fun facts</p>
<p>My best friend</p>
<p>I love mangoes.</p>
<h2>Our school trip</h2> - 2.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h4> or <h3>? (a) <h2> (b) <h4> (c) <h1> (d) <h3>
- 3.🔠 Which heading shows the BIGGEST text: <h3>, <h1>, <h5> or <h4>? (a) <h1> (b) <h4> (c) <h3> (d) <h5>
- 4.🌐 Which one saves our .html files? (a) a web server (b) a code editor (c) a web browser
-
5.💬 How many paragraphs show on the page?
<!-- <p>Our school trip</p> -->
<p>Fun facts</p>
<p>My best friend</p>
<!-- <p>I love mangoes.</p> --> - 6.📄 Can HTML on its own add up two numbers? (a) No (b) Yes
- 7.💬 Why do coders write comments? (a) to leave notes (b) to add colour (c) to show pictures (d) to make links
- 8.🔗 Which tag makes a clickable link? (a) <img> (b) <p> (c) <a> (d) <link>
- 9.Which of these goes in the body? (a) <link rel="stylesheet"> (b) <meta charset="utf-8"> (c) <img> (d) <style>
- 10.🔠 Which heading shows the BIGGEST text: <h3>, <h5>, <h2> or <h1>? (a) <h3> (b) <h5> (c) <h1> (d) <h2>
-
11.💬 Which text will NOT show on the page?
<!-- <p>Rain today</p> -->
<p>Cricket is fun.</p>
<p>Good morning!</p>
<p>Hello, world!</p> (a) Hello, world! (b) Rain today (c) Good morning! (d) Cricket is fun. - 12.🏷️ Which is the closing tag for <small>? (a) <small> (b) <\small> (c) </small> (d) <small/>
- 13.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 14.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as one space (b) as 5 spaces (c) as a dot (d) as a new line
- 15.Which of these is true of a web browser? (a) colours code to help us (b) turns HTML into a page (c) hosts websites online (d) stores a website’s files
- 16.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 17.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
- 18.🌐 Which one colours code to help us? (a) a web browser (b) a web server (c) a code editor
- 19.🔠 Which heading shows the BIGGEST text: <h4>, <h1>, <h6> or <h5>? (a) <h4> (b) <h6> (c) <h5> (d) <h1>
- 20.💬 Does the browser show comments on the page? (a) No (b) Yes
-
21.🔠 How many headings are in this code?
<h1>Rain today</h1>
<h4>My pets</h4>
<h3>Rain today</h3>
<p>Hello, world!</p> -
22.📝 How many paragraphs does this code make?
<p>I love mangoes.</p>
<h2>My best friend</h2>
<h2>Good morning!</h2> - 23.Which of these goes in the head? (a) <a> (b) <meta charset="utf-8"> (c) <p> (d) <ul>
-
24.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="250"> (a) tiger.jpg (b) A tiger asleep (c) width (d) A red kite -
25.💬 How many paragraphs show on the page?
<!-- <p>My best friend</p> -->
<p>Hello, world!</p>
<!-- <p>My pets</p> --> -
26.🔍 One closing tag is missing. Which one?
<i>I love mangoes.
<p>Our school trip</p>
<h1>Fun facts</h1> (a) </i> (b) </p> (c) </h1> (d) </h2> -
27.🔗 Which words do you click on?
<a href="games.html">School news</a> (a) School news (b) href (c) games.html (d) Take the quiz - 28.🏷️ Is </b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 29.🔍 Which is the odd one out? (a) opens web pages for us (b) shows line numbers (c) colours code to help us (d) saves our .html files
- 30.Which of these is an opening tag? (a) <b> (b) </p> (c) </title> (d) </body>
- 31.🔍 Which is the odd one out? (a) colours code to help us (b) opens web pages for us (c) has an address bar (d) shows pages from the web
-
32.📝 How many paragraphs does this code make?
<p>Rain today</p>
<h2>I love mangoes.</h2>
<h2>My pets</h2> - 33.True or false: <h1> is an empty tag. (a) False (b) True
- 34.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h5> or <h1>? (a) <h3> (b) <h5> (c) <h4> (d) <h1>
- 35.True or false: <ul> is an ordered list. (a) False (b) True
-
36.💬 Which text will NOT show on the page?
<p>Good morning!</p>
<!-- <p>Fun facts</p> -->
<p>Hello, world!</p>
<p>I love mangoes.</p> (a) Good morning! (b) Fun facts (c) I love mangoes. (d) Hello, world! -
37.📋 What number does the browser show next to “Litchi”?
<ol>
<li>Grapes</li>
<li>Mango</li>
<li>Banana</li>
<li>Litchi</li>
</ol> -
38.💬 How many paragraphs show on the page?
<!-- <p>Rain today</p> -->
<p>Our school trip</p>
<p>The red kite</p> - 39.🔠 Which heading shows the SMALLEST text: <h3>, <h6>, <h4> or <h1>? (a) <h3> (b) <h4> (c) <h6> (d) <h1>
-
40.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Cricket is fun.</h2>
<p>My best friend</p>
Answer key
- 4
- <h1>
- <h1>
- a code editor
- 2
- No
- to leave notes
- <a>
- <img>
- <h1>
- Rain today
- </small>
- No
- as one space
- turns HTML into a page
- an opening tag
- Yes
- a code editor
- <h1>
- No
- 3
- 1
- <meta charset="utf-8">
- A tiger asleep
- 1
- </i>
- School news
- a closing tag
- opens web pages for us
- <b>
- colours code to help us
- 1
- False
- <h1>
- False
- Fun facts
- 4
- 2
- <h6>
- 2
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids