1.4 Rendering & JavaScript ✦HighVerified

href=”#” or javascript:void(0) navigation

What it is

A link whose href is a bare hash or javascript:void(0) goes nowhere as far as a crawler is concerned. The real destination is hidden in script, so the link is not followed. Anchors with no real destination. No crawlable target, so linked content may be undiscoverable.

Why does href=”#” or javascript:void(0) navigation matter for AI search?

No crawlable target, so linked content may be undiscoverable.

How do you fix it?

Provide real URLs in href.

How do you find it on your site?

  1. Search the HTML for href values of # or javascript:void(0).
  2. Identify what each is meant to navigate to.
  3. Give each anchor a real, resolvable href.
  4. Confirm crawlers now follow them.

Which ranking and citation factors does it touch?

Links need a real href target to pass signals and be followed. Placeholder hrefs waste the link entirely.

What is the impact?

Medium-high. Direct.

What is the evidence?

Links need resolvable href targets to be followed. Google Search Central, Understand JavaScript SEO Basics

Frequently asked questions about href=”#” or javascript:void(0) navigation

What does "href=”#” or javascript:void(0) navigation" mean?

Anchors with no real destination.

How do you fix href=”#” or javascript:void(0) navigation?

Provide real URLs in href.