CourseHead vs. Body
Core Concept
100% Comprehensive
Head vs. Body.
An HTML document is split into two distinct zones: the Head (for the brain/settings) and the Body (for the eyes/content).
The Essentials
01
The <head> is for metadata, scripts, and styles (stuff you don't see).
02
The <body> is for all visible elements like text, images, and links.
03
There can be only one <head> and one <body> per document.
04
The <title> tag inside the <head> is what appears in the browser tab.
05
External CSS and Fonts are linked inside the <head>.
06
Content in the <head> is ignored by the visual rendering of the page.
Professional Insights
Metadata and SEO
The <head> is the primary place for SEO metadata. Tags like <meta name='description'> tell Google what your page is about.
Page Performance
Loading large styles in the <head> is standard, but loading large scripts in the <head> can slow down the initial page render.
Character Encoding
The <meta charset='UTF-8'> tag should always be near the top of the <head> to ensure special characters (like emojis) display correctly.
The Body's Role
Everything from the first <h1> to the final <footer> must live inside the <body>. Putting these in the <head> is a major structural error.
Critical Pitfalls
Putting <img> or <h1> tags inside the <head>.
Forgetting the <title> tag, which is required for a valid document.
Closing the <head> tag too late (after the <body> starts).
Putting <meta> tags inside the <body>.
Interactive Lab
Sprint Tasks
01
Move the <title> tag into the correct section02
Move the <h1> tag into the correct sectionLoading editor...
Production Preview