← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 418 · 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 part holds everything you see on the page? (a) the head (b) the body (c) the doctype (d) the title
  2. 2.🔠 How many heading levels does HTML have? (a) 3 (b) 4 (c) 10 (d) 6
  3. 3.🔗 Where does this link open?
    <a href="art.html" target="_blank">Art corner</a>
    (a) in a new tab (b) in the same tab
  4. 4.🔢 In a basic web page file, which comes LAST? (a) <!DOCTYPE html> (b) </body> (c) <html> (d) </html>
  5. 5.🔗 Which address opens when you click this link?
    <a href="art.html">About us</a>
    (a) About us (b) art.html (c) quiz.html (d) news.html
  6. 6.🔍 Which line is missing its closing tag?
    line 1: <h2>Rain today</h2>
    line 2: <b>Good morning!
    line 3: <i>Cricket is fun.</i>
    (a) line 2 (b) line 1 (c) line 3
  7. 7.🔍 Which line is missing its closing tag?
    line 1: <strong>Cricket is fun.
    line 2: <h2>Our school trip</h2>
    line 3: <em>The red kite</em>
    (a) line 1 (b) line 3 (c) line 2
  8. 8.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <!-- <p>My pets</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <p>My best friend</p>
  9. 9.True or false: in <img>, alt describes the picture. (a) False (b) True
  10. 10.🔗 Which tag makes a clickable link? (a) <a> (b) <p> (c) <link> (d) <img>
  11. 11.🌐 Which one has an address bar? (a) a code editor (b) a web server (c) a web browser
  12. 12.🖼️ Which picture file does the browser load?
    <img src="dog.jpg" alt="A happy dog" width="350">
    (a) dog.jpg (b) A happy dog (c) moon.png (d) bus.jpg
  13. 13.🔗 Which words do you click on?
    <a href="quiz.html">School news</a>
    (a) Take the quiz (b) quiz.html (c) School news (d) href
  14. 14.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <p>My best friend</p>
    <h2>The red kite</h2>
    <p>The red kite</p>
  15. 15.💬 How many paragraphs show on the page?
    <p>Cricket is fun.</p>
    <p>Fun facts</p>
    <!-- <p>Good morning!</p> -->
    <p>Our school trip</p>
  16. 16.🔗 What does target="_blank" do to a link? (a) makes it blank (b) opens it in a new tab (c) makes it bold (d) hides the link
  17. 17.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h3> or <h6>? (a) <h3> (b) <h1> (c) <h6> (d) <h2>
  18. 18.True or false: <h1> is an empty tag. (a) False (b) True
  19. 19.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Rain today</p>
    <p>Cricket is fun.</p>
    <p>The red kite</p>
  20. 20.📋 Which list tag shows bullet points? (a) <ol> (b) <ul> (c) <li>
  21. 21.📋 Which list suits a shopping list in any order? (a) <ol> (b) <br> (c) <hr> (d) <ul>
  22. 22.🔍 Which line is missing its closing tag?
    line 1: <h1>Hello, world!</h1>
    line 2: <strong>Fun facts</strong>
    line 3: <i>My pets
    (a) line 2 (b) line 3 (c) line 1
  23. 23.🔠 Which heading shows the SMALLEST text: <h2>, <h6>, <h3> or <h1>? (a) <h1> (b) <h6> (c) <h2> (d) <h3>
  24. 24.True or false: in <img>, width tells which image to load. (a) False (b) True
  25. 25.🔗 Which address opens when you click this link?
    <a href="games.html">Contact us</a>
    (a) contact.html (b) Contact us (c) about.html (d) games.html
  26. 26.True or false: in <img>, alt is read by screen readers. (a) True (b) False
  27. 27.💬 Which text will NOT show on the page?
    <!-- <p>My pets</p> -->
    <p>My best friend</p>
    <p>Good morning!</p>
    (a) My best friend (b) Good morning! (c) My pets
  28. 28.🌐 Which one answers page requests? (a) a code editor (b) a web server (c) a web browser
  29. 29.💾 A web page file usually ends with which extension? (a) .txt (b) .png (c) .mp3 (d) .html
  30. 30.📝 How many paragraphs does this code make?
    <p>Cricket is fun.</p>
    <p>I love mangoes.</p>
    <h2>Rain today</h2>
  31. 31.Which of these is true of a web browser? (a) is where we type code (b) turns HTML into a page (c) stores a website’s files (d) saves our .html files
  32. 32.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
    <p>My pets</p>
    (a) My pets (b) The red kite (c) My best friend (d) Hello, world!
  33. 33.🖼️ Does <img> need a closing tag? (a) No (b) Yes
  34. 34.🔠 Which heading shows the SMALLEST text: <h5>, <h2>, <h1> or <h6>? (a) <h1> (b) <h5> (c) <h6> (d) <h2>
  35. 35.📋 How many items does this list show?
    <ol>
      <li>Papaya</li>
      <li>Grapes</li>
      <li>Orange</li>
      <li>Banana</li>
      <li>Mango</li>
      <li>Litchi</li>
    </ol>
  36. 36.🧩 An opening tag + content + a closing tag together make an ___. (a) editor (b) attribute (c) address (d) element
  37. 37.🔗 Where does this link open?
    <a href="games.html" target="_blank">Take the quiz</a>
    (a) in the same tab (b) in a new tab
  38. 38.🔗 Which code links to about.html? (a) <link about.html> (b) <a src="about.html"> (c) <a href="about.html"> (d) <a alt="about.html">
  39. 39.📝 Does <b> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  40. 40.🔠 Which heading shows the BIGGEST text: <h1>, <h3>, <h4> or <h6>? (a) <h6> (b) <h1> (c) <h4> (d) <h3>

Answer key

  1. the body
  2. 6
  3. in a new tab
  4. </html>
  5. art.html
  6. line 2
  7. line 1
  8. 1
  9. True
  10. <a>
  11. a web browser
  12. dog.jpg
  13. School news
  14. 3
  15. 3
  16. opens it in a new tab
  17. <h1>
  18. False
  19. 3
  20. <ul>
  21. <ul>
  22. line 3
  23. <h6>
  24. False
  25. games.html
  26. True
  27. My pets
  28. a web server
  29. .html
  30. 2
  31. turns HTML into a page
  32. Hello, world!
  33. No
  34. <h6>
  35. 6
  36. element
  37. in a new tab
  38. <a href="about.html">
  39. has a closing tag
  40. <h1>

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