← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 600 · 40 questions
TalentJR

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. 1.📋 Which list suits a shopping list in any order? (a) <hr> (b) <br> (c) <ol> (d) <ul>
  2. 2.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h4> or <h2>? (a) <h1> (b) <h2> (c) <h4> (d) <h6>
  3. 3.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <p>Good morning!</p>
    <p>My best friend</p>
  4. 4.🌐 Which one answers page requests? (a) a web browser (b) a web server (c) a code editor
  5. 5.🔍 One closing tag is missing. Which one?
    <p>Fun facts</p>
    <small>Our school trip
    <b>I love mangoes.</b>
    (a) </em> (b) </p> (c) </small> (d) </b>
  6. 6.Which of these is true of a web server? (a) saves our .html files (b) shows pages from the web (c) shows line numbers (d) hosts websites online
  7. 7.🏷️ Is </b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  8. 8.🔗 Which address opens when you click this link?
    <a href="quiz.html">Visit the site</a>
    (a) Visit the site (b) quiz.html (c) about.html (d) games.html
  9. 9.🔠 Which heading shows the BIGGEST text: <h5>, <h6>, <h3> or <h2>? (a) <h6> (b) <h2> (c) <h3> (d) <h5>
  10. 10.🔠 Which tag is used for the main title on a page? (a) <h1> (b) <br> (c) <h6> (d) <p>
  11. 11.🔍 One closing tag is missing. Which one?
    <h1>I love mangoes.
    <strong>Cricket is fun.</strong>
    <p>Hello, world!</p>
    (a) </strong> (b) </h1> (c) </p> (d) </u>
  12. 12.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
  13. 13.🌐 Which one stores a website’s files? (a) a web browser (b) a web server (c) a code editor
  14. 14.🔗 Which words do you click on?
    <a href="art.html">Maths fun</a>
    (a) Art corner (b) href (c) Maths fun (d) art.html
  15. 15.Which of these is a closing tag? (a) <title> (b) <b> (c) <li> (d) </body>
  16. 16.True or false: <li> lists things in any order. (a) False (b) True
  17. 17.🔗 Which words do you click on?
    <a href="games.html">Visit the site</a>
    (a) Maths fun (b) Visit the site (c) href (d) games.html
  18. 18.💬 Which text will NOT show on the page?
    <p>Our school trip</p>
    <p>Fun facts</p>
    <p>Hello, world!</p>
    <!-- <p>My pets</p> -->
    (a) Hello, world! (b) Fun facts (c) Our school trip (d) My pets
  19. 19.💬 How many paragraphs show on the page?
    <p>The red kite</p>
    <p>My pets</p>
    <!-- <p>Cricket is fun.</p> -->
  20. 20.Which of these has a closing tag? (a) <img> (b) <b> (c) <br> (d) <meta>
  21. 21.Which of these is an opening tag? (a) </b> (b) </p> (c) </title> (d) <li>
  22. 22.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>Thanks for visiting.</p>
    </body>
    </html>
    (a) Thanks for visiting. (b) Art Gallery (c) index.html (d) Welcome!
  23. 23.💬 Which text will NOT show on the page?
    <!-- <p>Our school trip</p> -->
    <p>Cricket is fun.</p>
    <p>Hello, world!</p>
    (a) Hello, world! (b) Cricket is fun. (c) Our school trip
  24. 24.Which of these is true of a code editor? (a) shows pages from the web (b) shows line numbers (c) hosts websites online (d) opens web pages for us
  25. 25.🖼️ Which attribute of <img> describes the picture? (a) src (b) alt (c) height (d) width
  26. 26.💬 How many paragraphs show on the page?
    <!-- <p>Hello, world!</p> -->
    <p>Rain today</p>
    <!-- <p>Cricket is fun.</p> -->
    <!-- <p>Fun facts</p> -->
  27. 27.Which of these goes in the head? (a) <ul> (b) <img> (c) <p> (d) <link rel="stylesheet">
  28. 28.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="250">
  29. 29.🔗 What does target="_blank" do to a link? (a) makes it blank (b) makes it bold (c) opens it in a new tab (d) hides the link
  30. 30.📝 What does <p> make? (a) a picture (b) a link (c) a paragraph (d) a table
  31. 31.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="map.png" alt="Map of India" width="100">
    (a) map.png (b) Birthday cake (c) width (d) Map of India
  32. 32.📋 Which list tag is an unordered list? (a) <ul> (b) <li> (c) <ol>
  33. 33.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h1> or <h5>? (a) <h5> (b) <h6> (c) <h1> (d) <h3>
  34. 34.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <h2>Good morning!</h2>
    <p>Rain today</p>
    <p>Good morning!</p>
    <h2>Our school trip</h2>
  35. 35.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <p>The red kite</p>
    <p>Good morning!</p>
    <h2>I love mangoes.</h2>
    <h2>Our school trip</h2>
  36. 36.🔠 How many headings are in this code?
    <h1>The red kite</h1>
    <p>Fun facts</p>
    <p>Good morning!</p>
    <p>The red kite</p>
  37. 37.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <p>My pets</p>
    <p>My best friend</p>
    <!-- <p>I love mangoes.</p> -->
    (a) My best friend (b) Good morning! (c) I love mangoes. (d) My pets
  38. 38.🏷️ Is <p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  39. 39.True or false: <li> is an unordered list. (a) False (b) True
  40. 40.🔗 Which address opens when you click this link?
    <a href="about.html">About us</a>
    (a) About us (b) contact.html (c) about.html (d) https://example.com

Answer key

  1. <ul>
  2. <h1>
  3. 3
  4. a web server
  5. </small>
  6. hosts websites online
  7. a closing tag
  8. quiz.html
  9. <h2>
  10. <h1>
  11. </h1>
  12. Yes
  13. a web server
  14. Maths fun
  15. </body>
  16. False
  17. Visit the site
  18. My pets
  19. 2
  20. <b>
  21. <li>
  22. Art Gallery
  23. Our school trip
  24. shows line numbers
  25. alt
  26. 1
  27. <link rel="stylesheet">
  28. 250
  29. opens it in a new tab
  30. a paragraph
  31. Map of India
  32. <ul>
  33. <h1>
  34. 3
  35. 3
  36. 1
  37. I love mangoes.
  38. an opening tag
  39. False
  40. about.html

Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids