Document Type Declaration

What is a document type declaration?

It is a basic part of the code placed at the beginning of an HTML document. It is used to ensure that web browsers interpret the content of the HTML document correctly.

The document type declaration for HTML looks like this:

<!DOCTYPE html>

For the rest of the course, the declaration will be automatically added to your HTML documents, but it is important to remember it so that your HTML document is not incorrectly interpreted by the browser, which could cause significant display issues.

Instructions

Write the HTML document type declaration on the first line of the code.

Start programming for free

By signing up, you agree to the Terms of Service and Privacy Policy.

Or sign up with:

3/9

Document Type Declaration | Start Coder