Loading...
HTML <!DOCTYPE> Tag

HTML <!DOCTYPE> Tag

In this tutorial, we will learn about doctype tag in HTML with the help of examples.


<!DOCTYPE> Tag

<!DOCTYPE> declaration is used to determine the type of document and the version of HTML used in the document.
It is always used before the <html> tag in the HTML document.
<!DOCTYPE> declaration is not compulsory to write.

Syntax

<!DOCTYPE html>

Note : <!DOCTYPE> declaration is not case-sensitive.

Example

<!DOCtype html>
<!dOcTyPe html>
<!docTYPE html>
<!doctype html>

All of the above <!DOCTYPE> declarations are correct.


Next Tutorial

We hope that this tutorial helped you develop better understanding of the concept of doctype tag in HTML.

Keep Learning : )

In the next tutorial, you'll learn about HTML a Tag.

- Related Topics