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 heading shows the BIGGEST text: <h1>, <h5>, <h6> or <h4>? (a) <h6> (b) <h4> (c) <h5> (d) <h1>
- 2.🔠 Which heading shows the BIGGEST text: <h1>, <h3>, <h5> or <h2>? (a) <h2> (b) <h5> (c) <h3> (d) <h1>
-
3.📝 How many paragraphs does this code make?
<p>Cricket is fun.</p>
<p>Good morning!</p>
<p>Hello, world!</p> -
4.🔍 Which line is missing its closing tag?
line 1: <u>The red kite
line 2: <em>I love mangoes.</em>
line 3: <i>My pets</i> (a) line 3 (b) line 1 (c) line 2 - 5.🏷️ Is <h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
6.💬 How many paragraphs show on the page?
<p>The red kite</p>
<!-- <p>My best friend</p> -->
<!-- <p>My pets</p> --> -
7.🔍 Which line is missing its closing tag?
line 1: <strong>Our school trip</strong>
line 2: <small>My pets</small>
line 3: <h2>Good morning! (a) line 1 (b) line 3 (c) line 2 - 8.Which of these goes in the head? (a) <p> (b) <a> (c) <style> (d) <ul>
- 9.🖼️ Which attribute of <img> is read by screen readers? (a) height (b) src (c) alt (d) width
-
10.📋 Does this list show bullets or numbers?
<ul>
<li>Banana</li>
<li>Litchi</li>
</ul> (a) numbers (b) bullets - 11.🔗 Which code links to about.html? (a) <a src="about.html"> (b) <a href="about.html"> (c) <link about.html> (d) <a alt="about.html">
- 12.Which of these is true of a code editor? (a) answers page requests (b) sends pages over the net (c) colours code to help us (d) hosts websites online
-
13.📋 How many items does this list show?
<ul>
<li>Orange</li>
<li>Papaya</li>
<li>Mango</li>
<li>Banana</li>
<li>Grapes</li>
</ul> - 14.💬 How does an HTML comment end? (a) */ (b) >> (c) // (d) -->
- 15.Which of these is true of a code editor? (a) opens web pages for us (b) hosts websites online (c) has an address bar (d) shows line numbers
-
16.📋 What number does the browser show next to “Banana”?
<ol start="8">
<li>Orange</li>
<li>Banana</li>
<li>Mango</li>
<li>Jamun</li>
</ol> -
17.🔗 Which words do you click on?
<a href="news.html">Contact us</a> (a) Contact us (b) news.html (c) href (d) Visit the site - 18.🔠 How many heading levels does HTML have? (a) 10 (b) 3 (c) 6 (d) 4
- 19.True or false: <ol> lists things in any order. (a) True (b) False
-
20.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Sky is blue<br>Stars shine<br>Kites fly high</p> -
21.🔍 Which line is missing its closing tag?
line 1: <u>Fun facts
line 2: <em>I love mangoes.</em>
line 3: <h2>My pets</h2> (a) line 2 (b) line 3 (c) line 1 - 22.📄 Which part holds everything you see on the page? (a) the title (b) the doctype (c) the head (d) the body
- 23.Which of these is true of a code editor? (a) hosts websites online (b) opens web pages for us (c) saves our .html files (d) has an address bar
-
24.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>My pets</p>
<p>Rain today</p> (a) My pets (b) Rain today (c) Our school trip -
25.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="350"> (a) Map of India (b) kite.png (c) A red kite (d) width - 26.🏷️ Which is the closing tag for <h1>? (a) </h1> (b) <\h1> (c) <h1/> (d) <h1>
- 27.True or false: a code editor sends pages over the net. (a) True (b) False
-
28.🔗 Which words do you click on?
<a href="quiz.html">Maths fun</a> (a) quiz.html (b) href (c) Art corner (d) Maths fun - 29.🔠 Which heading shows the BIGGEST text: <h2>, <h4>, <h6> or <h1>? (a) <h1> (b) <h4> (c) <h2> (d) <h6>
-
30.🔗 Where does this link open?
<a href="maths.html" target="_blank">Visit the site</a> (a) in the same tab (b) in a new tab - 31.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a dot . (c) a dollar $ (d) a slash /
- 32.True or false: <ul> has a closing tag. (a) False (b) True
-
33.🔗 Where does this link open?
<a href="about.html" target="_blank">Art corner</a> (a) in the same tab (b) in a new tab - 34.🌐 Which one turns HTML into a page? (a) a code editor (b) a web browser (c) a web server
-
35.💬 How many paragraphs show on the page?
<!-- <p>Good morning!</p> -->
<p>The red kite</p>
<!-- <p>Hello, world!</p> -->
<!-- <p>Cricket is fun.</p> --> - 36.📄 Where does <link rel="stylesheet"> go: in the head or in the body? (a) in the body (b) in the head
- 37.📝 What does <br> do? (a) makes text bold (b) adds a picture (c) starts a new line (d) makes a list
-
38.📋 Does this list show bullets or numbers?
<ol>
<li>Jamun</li>
<li>Banana</li>
<li>Grapes</li>
</ol> (a) bullets (b) numbers - 39.🏷️ Is <p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 40.📋 Which list tag is an unordered list? (a) <ol> (b) <li> (c) <ul>
Answer key
- <h1>
- <h1>
- 3
- line 1
- an opening tag
- 1
- line 3
- <style>
- alt
- bullets
- <a href="about.html">
- colours code to help us
- 5
- -->
- shows line numbers
- 9
- Contact us
- 6
- False
- 4
- line 1
- the body
- saves our .html files
- Our school trip
- A red kite
- </h1>
- False
- Maths fun
- <h1>
- in a new tab
- a slash /
- True
- in a new tab
- a web browser
- 1
- in the head
- starts a new line
- numbers
- an opening tag
- <ul>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids