In one sentence: pick one URL form, enforce it with a redirect in code, make the canonical tag and the sitemap agree with it, and accept that consolidating an index that already split takes weeks — which is why this is worth fixing before you publish more pages.

What splitting actually costs

We ran this experiment on ourselves involuntarily. A trailing-slash inconsistency left 46 pages indexed under two URLs each. Impressions and average position were computed separately for each twin — roughly 1,980 impressions divided across pairs, with neither version accumulating enough signal to rank properly. One article appeared at position 39.8 as the no-slash version and 40.5 with the slash: the same content, evaluated twice, competing with itself.

Nothing errors. The build passes, the pages render, analytics looks normal. The only symptom is that nothing quite ranks.

The forms that duplicate

PairUsual cause
/page and /page/Framework default disagreeing with links or the sitemap
www and apexNo redirect at the server level; both serve 200
http and httpsIncomplete redirect after a certificate change
Query-string variantsTracking parameters not stripped or not canonicalised
Uppercase and lowercase pathsCase-insensitive server, case-sensitive links

Fix it in the right order

  • Decide the form and enforce it in code, so every generated link, the canonical tag and the sitemap agree by construction rather than by discipline.
  • Redirect with a 301, preserving path and query. A redirect that sends every deep URL to the homepage is a soft 404 factory — it returns 200 for content that does not exist there, which is worse than the duplicate you were fixing.
  • Make the canonical tag point at the enforced form, absolute, on every page including the canonical one itself.
  • Resubmit the sitemap so consolidation starts sooner. Expect four to eight weeks before the index settles.

The canonical tag is a hint, not an instruction

A canonical tag pointing somewhere while internal links, the sitemap and the redirect chain point elsewhere is a contradiction, and a contradiction gets resolved by the crawler rather than by you. The tag only works when everything else already agrees with it — which means the tag is the last step, not the fix.

Why this comes before publishing more

Duplication scales with the site. Fixing it at 400 URLs is a routing change; fixing it at 4,000 is the same routing change plus ten times the index debt and ten times the wait. If you are planning to grow the page count, this is the thing to close first.