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 tag makes a clickable link? (a) <link> (b) <a> (c) <img> (d) <p>
- 2.🔠 How many <h1> headings should a page usually have? (a) 1 (b) 10 (c) 3 (d) 6
- 3.True or false: <a> goes in the head. (a) True (b) False
- 4.🏷️ Is <b> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 5.True or false: <ul> is one item of a list. (a) True (b) False
-
6.💬 Which text will NOT show on the page?
<p>My best friend</p>
<!-- <p>My pets</p> -->
<p>The red kite</p> (a) The red kite (b) My best friend (c) My pets - 7.True or false: <ul> goes in the head. (a) False (b) True
- 8.🔗 Which code links to about.html? (a) <link about.html> (b) <a alt="about.html"> (c) <a href="about.html"> (d) <a src="about.html">
- 9.🔠 Which heading shows the SMALLEST text: <h1>, <h4>, <h2> or <h6>? (a) <h1> (b) <h2> (c) <h6> (d) <h4>
- 10.🖼️ Which tag puts a picture on a page? (a) <a> (b) <pic> (c) <img> (d) <p>
-
11.📝 On how many lines does the browser show this paragraph?
<p>Stars shine<br>Roses are red</p> -
12.🔍 Which line is missing its closing tag?
line 1: <h2>The red kite</h2>
line 2: <h1>I love mangoes.</h1>
line 3: <em>Good morning! (a) line 1 (b) line 2 (c) line 3 - 13.🔠 Which heading shows the SMALLEST text: <h3>, <h2>, <h6> or <h5>? (a) <h3> (b) <h5> (c) <h2> (d) <h6>
- 14.Which of these is true of a code editor? (a) stores a website’s files (b) is where we type code (c) turns HTML into a page (d) shows pages from the web
- 15.📄 Can HTML on its own keep a high score? (a) No (b) Yes
-
16.🔍 Which line is missing its closing tag?
line 1: <h2>Good morning!</h2>
line 2: <h3>I love mangoes.</h3>
line 3: <u>Our school trip (a) line 1 (b) line 3 (c) line 2 -
17.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="250"> (a) kite.png (b) A red kite (c) cake.jpg (d) map.png - 18.🌐 Which one saves our .html files? (a) a web server (b) a code editor (c) a web browser
-
19.💬 Which text will NOT show on the page?
<p>My best friend</p>
<p>The red kite</p>
<p>Fun facts</p>
<!-- <p>My pets</p> --> (a) The red kite (b) My best friend (c) My pets (d) Fun facts -
20.🔗 Where does this link open?
<a href="news.html">Play games</a> (a) in the same tab (b) in a new tab -
21.💬 How many paragraphs show on the page?
<p>My best friend</p>
<p>Cricket is fun.</p>
<p>Rain today</p>
<!-- <p>My pets</p> --> -
22.🔍 One closing tag is missing. Which one?
<em>The red kite</em>
<i>My best friend
<p>Our school trip</p> (a) </i> (b) </em> (c) </p> (d) </strong> - 23.🔠 Which heading shows the SMALLEST text: <h5>, <h2>, <h4> or <h6>? (a) <h2> (b) <h4> (c) <h5> (d) <h6>
- 24.🔠 How many heading levels does HTML have? (a) 10 (b) 4 (c) 6 (d) 3
- 25.Which of these is a closing tag? (a) <title> (b) <h1> (c) <b> (d) </p>
- 26.🖼️ Which attribute of <img> describes the picture? (a) height (b) width (c) src (d) alt
-
27.🔠 How many headings are in this code?
<h1>My best friend</h1>
<p>My pets</p>
<h3>My best friend</h3>
<h3>My best friend</h3>
<h4>Cricket is fun.</h4> -
28.🖼️ Which picture file does the browser load?
<img src="bus.jpg" alt="Our school bus" width="150"> (a) Our school bus (b) tiger.jpg (c) fort.jpg (d) bus.jpg - 29.📝 What does <p> make? (a) a table (b) a link (c) a picture (d) a paragraph
- 30.🔤 In “HTML”, what does the M stand for? (a) Markup (b) Mouse (c) Modern (d) Machine
- 31.Which of these is an empty tag? (a) <h1> (b) <b> (c) <li> (d) <br>
- 32.📛 In <a href="x.html">, what is href? (a) a closing tag (b) a comment (c) an element name (d) an attribute
- 33.🔠 Are headings shown in bold by default? (a) Yes (b) No
- 34.🏷️ Which is the closing tag for <u>? (a) <u> (b) </u> (c) <\u> (d) <u/>
-
35.🔗 Which words do you click on?
<a href="contact.html">About us</a> (a) contact.html (b) href (c) Contact us (d) About us -
36.💬 How many paragraphs show on the page?
<p>Fun facts</p>
<!-- <p>Cricket is fun.</p> -->
<p>Hello, world!</p> - 37.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to colour it (c) to load it faster (d) to describe the image
-
38.📝 How many paragraphs does this code make?
<p>My pets</p>
<p>I love mangoes.</p>
<h2>Fun facts</h2>
<h2>Fun facts</h2>
<p>Cricket is fun.</p> -
39.🖼️ How many pixels wide is the picture drawn?
<img src="map.png" alt="Map of India" width="250"> - 40.True or false: <li> shows bullet points. (a) True (b) False
Answer key
- <a>
- 1
- False
- an opening tag
- False
- My pets
- False
- <a href="about.html">
- <h6>
- <img>
- 2
- line 3
- <h6>
- is where we type code
- No
- line 3
- kite.png
- a code editor
- My pets
- in the same tab
- 3
- </i>
- <h6>
- 6
- </p>
- alt
- 4
- bus.jpg
- a paragraph
- Markup
- <br>
- an attribute
- Yes
- </u>
- About us
- 2
- to describe the image
- 3
- 250
- False
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids