Fixing URL Redirects with Canonical tag Fixing URL Redirects with Canonical tag

Andy • November 12, 2025

seo

Understanding Canonical Tags: Fixing Trailing Slash Redirect Issues in Google Search Console

If you’ve seen duplicate page or redirect warnings in Google Search Console caused by URLs that differ only by a trailing slash (such as /about vs /about/), you’re not alone. This is a common SEO issue that can split ranking signals across two versions of the same page. The solution lies in using canonical tags correctly.

What Is a Canonical Tag?

A canonical tag (<link rel="canonical" href="...">) tells search engines which version of a page is the primary or preferred one to index. It helps consolidate signals like backlinks, crawl budget, and page authority, ensuring that only the canonical URL appears in search results.

Here’s how a canonical tag looks in your page’s <head> section:

<link rel="canonical" href="https://ilminster.net/pages/about/" />

This tag indicates that the trailing slash version of the page is the canonical one.

The Trailing Slash Problem Explained

Many websites can be accessed both with and without a trailing slash:

  • https://ilminster.net/pages/about
  • https://ilminster.net/pages/about/

Search engines often treat these as two separate URLs, even if they display the same content. Without guidance, Google might index both versions, leading to:

  • Duplicate content warnings in Google Search Console
  • Indexed redirects (one URL redirecting to the other)
  • Diluted link equity between duplicates

How to Fix Trailing Slash Issues with Canonicals

Follow these steps to resolve the issue cleanly:

  1. Pick a preferred URL format. Decide whether you want to use a trailing slash or not (stick to one site-wide).

  2. Set up proper server redirects. Use 301 redirects so non-preferred URLs point to the preferred version.

    Example Apache .htaccess rule (to force trailing slashes):

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_URI} !(.*)/$
    RewriteRule ^(.*)$ https://ilminster.net/$1/ [L,R=301]
    
  3. Add canonical tags site-wide. In your page templates, output the canonical URL consistently. For example, in PHP:

    <link rel="canonical" href="https://ilminster.net<?= rtrim($_SERVER['REQUEST_URI'], '/') ?>/" />
    
  4. Verify in Google Search Console. After Google re-crawls your site, the duplicate warnings should disappear and only canonical URLs should remain indexed.

Why Canonical Tags Matter for SEO

Using canonical tags creates a clear hierarchy for your content, helping Google understand which version to index and rank. This improves crawl efficiency and prevents ranking dilution from duplicate pages.

When paired with redirects, canonical tags form a strong signal about your preferred URLs—ideal for managing trailing slash inconsistencies.