1.1 Robots & directives (HTTP + HTML)MediumVerified

Directive placed in <body> not <head>

What it is

A robots meta tag only counts when it is in the head. I sometimes find one injected into the body by a component, where Google may ignore it, so the page does not behave the way the tag implies. A robots meta tag outside the head.

Why does directive placed in <body> not <head> matter for AI search?

Robots meta tags are only honoured in the head; a misplaced one is ignored, so intended noindex/nosnippet silently fails.

How do you fix it?

Move the tag into <head>.

How do you find it on your site?

  1. View source and confirm the robots meta tag sits inside the head.
  2. If it is in the body, treat the directive as unreliable.
  3. Find the template or component injecting it in the wrong place.
  4. Move it into the head, or set the directive via the HTTP header instead.

Which ranking and citation factors does it touch?

A directive in the body can be silently ignored, which means a page you think is noindexed may be indexed, or the reverse. Either way the behaviour is unpredictable until it is fixed.

What is the impact?

Medium, intended control silently lost. Direct.

What is the evidence?

Robots meta tags must be in the head to be processed. Google Search Central, Robots Meta Tags Specifications

Frequently asked questions about directive placed in <body> not <head>

What does "Directive placed in <body> not <head>" mean?

A robots meta tag outside the head.

How do you fix directive placed in <body> not <head>?

Move the tag into <head>.