The doctype declaration specifies which version of HTML is used in a document. It has a direct effect on whether your HTML will validate.