What is the use of Doctype in Html ?

In this article, we will understand the use of Doctype Html and the difference in all the HTML versions. 

  • The DOCTYPE is basically used in the HTML page to identify the version of HTML content.
  • The important use of it is, that it defines the mode selection of the browser that it will run in the W3C standard mode, not in the quirks mode.

W3C Standard

W3C Standard defines an Open Web Platform for application development that enable developers to build rich and interactive web applications. It has some standard rules or strategies to build web pages.  

Quirks Mode

In the quirks mode, the application will not follow the W3C Standard for web page development, instead, it will run in backward compatibility.

Declaration of DOCTYPE

The DOCTYPE declaration is always at the top of the HTML page.



I am a Software Engineer, Web Developer, Youtuber, Blogger.

Leave a Reply

Your email address will not be published.