HTML Basics Quiz
Want to learn more than this quiz offers you? Have a look at my Frontend web
development courses.
Create an account and save your quiz results
Login and save your results
OR
Question 1/15
Which HTML attribute is used to specify the size of an input field?
Select your answer
Question 2/15
Which attribute is used to provide an alternate text for an image, if the image cannot be displayed?
Select your answer
Question 3/15
What is the HTML tag for making a dropdown list?
Select your answer
Question 4/15
What does HTML stand for?
Select your answer
Question 5/15
Which element is used to create a line break in HTML?
Select your answer
Question 6/15
Which tag is used to insert an image in HTML?
Select your answer
Question 7/15
Which HTML element is the largest heading?
Select your answer
Question 8/15
Which attribute is mandatory for the
<img>
tag?
Select your answer
Question 9/15
Which of the following is a valid HTML comment?
Select your answer
Question 10/15
Which element is used to define emphasized text in HTML?
Select your answer
Question 11/15
Which of the following tags is used to create an unordered list?
Select your answer
Question 12/15
What is the purpose of the
<meta charset="UTF-8">
tag in HTML?
Select your answer
Question 13/15
What is the correct simple DOCTYPE declaration for an HTML5 document?
Select your answer
Question 14/15
Which of the following HTML tags is used to make text italic?
Select your answer
Question 15/15
What's the primary HTML element used for writing bold text?
Select your answer
Your Results
You did not answer any questions correctly.
Your Answers
Question 1/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which HTML attribute is used to specify the size of an input field?
Available answers
The
size
attribute is used in HTML to specify the visible width of an <input>
element.
Question 2/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which attribute is used to provide an alternate text for an image, if the image cannot be displayed?
Available answers
The
alt
attribute specifies the alternate text for an image if it cannot be displayed. It is used for accessibility and SEO purposes.
Question 3/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
What is the HTML tag for making a dropdown list?
Available answers
The
<select>
tag is used in HTML to create a dropdown list.
Question 4/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
What does HTML stand for?
Available answers
HTML stands for Hypertext Markup Language, which is the standard language for creating web pages.
Question 5/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which element is used to create a line break in HTML?
Available answers
The
<br>
element is used to create a line break in HTML, effectively breaking the line at that point in the text.
Question 6/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which tag is used to insert an image in HTML?
Available answers
The
<img>
tag is used in HTML to embed images in web pages.
Question 7/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which HTML element is the largest heading?
Available answers
The
<h1>
element is the largest heading in HTML, typically used for main titles.
Question 8/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which attribute is mandatory for the <pre><code><img></code></pre> tag?
Available answers
The
src
attribute is mandatory for the <img>
tag as it specifies the path to the image to be displayed.
Question 9/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which of the following is a valid HTML comment?
Available answers
HTML comments are written inside
<!-- -->
tags, making <!-- This is a comment -->
the correct format for an HTML comment.
Question 10/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which element is used to define emphasized text in HTML?
Available answers
The
<em>
tag is used to define emphasized text, providing semantic emphasis usually displayed in italic.
Question 11/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which of the following tags is used to create an unordered list?
Available answers
The
<ul>
tag is used to create an unordered list, which typically displays as a bulleted list.
Question 12/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
What is the purpose of the <pre><code><meta charset="UTF-8"></code></pre> tag in HTML?
Available answers
The
<meta charset="UTF-8">
tag sets the character encoding for the HTML document to UTF-8, which is a Unicode character set that can represent every character in every language.
Question 13/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
What is the correct simple DOCTYPE declaration for an HTML5 document?
Available answers
The correct DOCTYPE declaration for HTML5 is
<!DOCTYPE html>
, which is simple and universal.
Question 14/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
Which of the following HTML tags is used to make text italic?
Available answers
The
<i>
tag is used to italicize text in HTML.
Question 15/15
😊 Your
answer was correct
🙁 Your
answer was incorrect
What's the primary HTML element used for writing bold text?
Available answers
The
<b>
tag is primarily used to make the text bold. While <strong>
also makes text bold, it has additional semantic meaning.