The document skeleton (DOCTYPE, html, head, body)
The declaration that must appear on the very first line of every HTML file, telling the browser the document uses modern HTML.
Understanding The document skeleton (DOCTYPE, html, head, body) in HTML & CSS
What it does: <head> contains information about the page such as its title and stylesheets, none of which appears in the browser window. The <html> tag is the outermost container. Both <head> and <body> are nested directly inside it. <!DOCTYPE html> must be the very first line - it tells the browser this is a modern HTML document. The exclamation mark before DOCTYPE is required. <DOCTYPE html> without it is not a valid declaration. Headings, paragraphs, images, and links all go inside <body>, the visible section of the skeleton.
Common mistakes: The DOCTYPE declaration must start with an exclamation mark: <!DOCTYPE html>. Writing <DOCTYPE html> is missing the ! and is invalid. The <html> opening tag is missing its closing angle bracket >. It should be <html>, not <html without the >.
Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.
This module's key terms are also in a printable crossword (Modules 1–12) and word search (Modules 1–23).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
<!DOCTYPE html>Fill in the Blanks
Spot the Error
Student with a class code? Join your class →