
What a multiple head tags error is
The HTML spec is blunt about this: a document has one <head> and one <body>. The head is where all the machine readable metadata lives, the title, meta description, canonical link, robots directives, hreflang, Open Graph tags, and your CSS and script references. When a page ships with two <head> elements, the document is malformed. It might still render, because browsers are forgiving, but "it still renders" is doing a lot of heavy lifting there.
What actually happens is the browser's HTML parser tries to recover. Per the spec's parsing rules, once the parser has closed the head and moved into the body, a second <head> start tag is simply ignored, and its children get reparented, often shoved into the body where meta tags do nothing. So the tags in that second head are not "also counted." They are frequently thrown away or relocated to a spot where search engines will not read them as head metadata.
Why it matters for SEO
The head is where your most important SEO directives live, so a broken head is a broken instruction set. Here is the practical damage:
- Canonical confusion. If your rel=canonical sits in the second head and the parser drops or relocates it, Google may never see it and may pick its own canonical. Two canonicals across two heads is worse, because now you are sending conflicting signals.
- Robots meta ignored. A noindex or nofollow directive that lands in the orphaned head can be missed, so a page you meant to keep out of the index gets indexed, or vice versa.
- Title and description loss. If the real title is in head one and a duplicate empty title is in head two, you can end up with a mess in the SERP snippet.
- Truncated head. When the parser closes the head early to recover, everything after that point (scripts, hreflang, structured data) can fall outside where it belongs, breaking rich results and rendering.
None of this is guaranteed catastrophic on every page, but it is the kind of quiet, inconsistent breakage that makes rankings wobble and drives you slowly insane during debugging. Malformed HTML around the head is worth fixing on principle, because you cannot reliably predict which tag gets eaten.
What causes it
| Cause | Where it shows up |
|---|---|
| Template includes a partial header twice | Custom themes, nested includes |
| Two plugins each printing a <head> | WordPress, plugin conflicts |
| Page builder wrapping content in a full doc | Builders that output whole pages |
| Tag manager or A/B tool injecting a head | GTM custom HTML, experiment scripts |
| Bad string concatenation in server code | Manual HTML assembly |
How to detect it
- View source, not inspect. Open view-source: on the URL and search the raw HTML for <head. The browser DevTools Elements panel shows the corrected DOM, which hides the problem. You need the raw response.
- Screaming Frog custom search: add a custom extraction or search rule counting occurrences of <head> and flag any page with more than one. This scales the check across the whole site.
- curl the URL: a quick
curl -s URL | grep -o "<head" | wc -ltells you how many head start tags the server actually sent. - W3C validator: paste the page or URL into the Nu HTML Checker; a stray head throws a clear parse error.
- Sitebulb / other crawlers: most surface HTML validity and duplicate head issues in their hints.
How to fix it, step by step
- Confirm from the raw HTML. Use view-source or curl, not the rendered DOM, so you are debugging what the server actually emits.
- Find which layer prints the second head. Bisect. Disable plugins one at a time, or comment out template includes, and re-check the raw source until the duplicate disappears. In WordPress this is usually two things both hooking the header, or a header partial included twice.
- Remove the duplicate at the source. Do not try to paper over it with JavaScript that deletes the second head after load. Googlebot may read the raw HTML before that runs, and you are still shipping invalid markup. Fix the template or the plugin.
- Consolidate the important tags. Make sure the surviving single head contains your canonical, robots meta, title, description, hreflang, and structured data. Nothing SEO critical should be sitting in the body.
- Re-validate. Run the page through the Nu HTML Checker and re-crawl in Screaming Frog to confirm exactly one head across templates.
- Check the whole template family. A duplicate head is almost always a template level bug, so if the product page has it, the category and blog templates probably do too. Test one URL of each type.
- Debug from raw view-source or curl output
- Fix the duplicate at the template or plugin level
- Keep every SEO directive in the one real head
- Re-validate with the Nu HTML Checker
- Check every template type, not just one page
- Trust the DevTools DOM, it hides the bug
- Delete the second head with client side JS
- Leave canonical or robots meta in the body
- Assume it is one page when it is a template
- Ignore it because the page still renders
What good looks like
One <head> per document, closed cleanly before <body> opens, containing exactly one title, one meta description, one canonical, the right robots directive, and your hreflang and structured data. The Nu HTML Checker returns no head related errors, and Screaming Frog reports a single head element across the whole crawl. Boring and correct, which is exactly what you want from your HTML skeleton.
FAQ
Will two head tags always hurt my rankings?
Why does the DevTools inspector show only one head?
Can Google Tag Manager cause this?
Is one head with duplicate meta tags the same problem?
Malformed head markup usually travels with other template level issues. A full audit surfaces them before they cost you indexation.
Claude Vincent is a technical SEO consultant focused on crawlability, rendering, and AI-search visibility. He writes the field guides and case studies at SEO ProCheck, with a bias toward the durable, unglamorous work that decides whether search engines and AI answer engines can actually read and cite a site.
About SEO ProCheck
Technical SEO consulting and GEO strategy with 20 years of enterprise experience. Case studies, resources, and tools for search and AI visibility.
Work With Me
Technical SEO audits, GEO strategy, site migrations, and international SEO. Hourly consulting for teams who need hands-on support, not just reports.







