The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. On-Page / Site Optimization
    4. Correct use of Canonical link vs 301 redirect

    Correct use of Canonical link vs 301 redirect

    On-Page / Site Optimization
    4 3 709
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • wedmonds
      wedmonds last edited by

      Hi All,

      Seeking yet more advice.

      SEOMOZ tools have told me I have duplicate content on one of my sites and I am keen to clean this up.  I am not to familiar with the following so thought I would ask.

      The duplicate content is shown on :

      www.mysite.com

      www.mysite.com/index.html

      Obviously I only see index.html when I check the code so what is the best method of resolving the duplicate content, Canonical or 301?

      Can you give me an example 🙂

      Thanks all

      1 Reply Last reply Reply Quote 0
      • seanmccauley
        seanmccauley last edited by

        Use a 301 Redirect with .htaccess. Use the following code in your 'htaccess file:

        Options +FollowSymLinks
        RewriteCond %{THE_REQUEST} ^./index.html
        RewriteRule ^(.
        )index.html$ http://www.yoursite.com/$1 [R=301,L]

        1 Reply Last reply Reply Quote 2
        • RyanKent
          RyanKent last edited by

          Wayne,

          A 301 is always preferred over a canonical when given the choice. You would use a canonical if you did not have access to your web server and did not have a better option.

          The method of redirect depends on the hardware and software of your server. The most common shared servers use Apache and cPanel where there is a Redirect tool which allows you to perform this redirect. The Redirect tool writes the htaccess code for you.

          You are also welcome to use the code Sean shared but if you have not modified your file before please understand any mistake can make your site inaccessible. Always back up the current file, make the change, and thoroughly test it.

          1 Reply Last reply Reply Quote 2
          • wedmonds
            wedmonds last edited by

            Thanks guys, exactly what I was looking for 🙂

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post
            • After HTTPS upgrade, should I change all internal links, or a general 301 redirect is better?
              DmitriiK
              DmitriiK
              0
              7
              4.2k

            • 301 redirects. If new website is a different business does it still send link authority?
              isaac663
              isaac663
              0
              3
              134

            • I'm using Canonical URL but still receiving message - Appropriate Use of Rel Canonical
              KeriMorgret
              KeriMorgret
              0
              7
              85

            • Redirecting deleted posts 301 vs 302
              redfishking
              redfishking
              0
              6
              614

            • Dealing with thin content/95% duplicate content - canonical vs 301 vs noindex
              MiriamEllis
              MiriamEllis
              0
              4
              612

            • Which pages should use rel="canonical" links?
              Highland
              Highland
              0
              7
              340

            • Google found bad links delete them or 301 redirect?
              ShaMenz
              ShaMenz
              0
              5
              753

            • Recreate missing pages or just use 301 redirect?
              seoninja20
              seoninja20
              0
              2
              757

            Get started with Moz Pro!

            Unlock the power of advanced SEO tools and data-driven insights.

            Start my free trial
            Products
            • Moz Pro
            • Moz Local
            • Moz API
            • Moz Data
            • STAT
            • Product Updates
            Moz Solutions
            • SMB Solutions
            • Agency Solutions
            • Enterprise Solutions
            • Digital Marketers
            Free SEO Tools
            • Domain Authority Checker
            • Link Explorer
            • Keyword Explorer
            • Competitive Research
            • Brand Authority Checker
            • Local Citation Checker
            • MozBar Extension
            • MozCast
            Resources
            • Blog
            • SEO Learning Center
            • Help Hub
            • Beginner's Guide to SEO
            • How-to Guides
            • Moz Academy
            • API Docs
            About Moz
            • About
            • Team
            • Careers
            • Contact
            Why Moz
            • Case Studies
            • Testimonials
            Get Involved
            • Become an Affiliate
            • MozCon
            • Webinars
            • Practical Marketer Series
            • MozPod
            Connect with us

            Contact the Help team

            Join our newsletter
            Moz logo
            © 2021 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
            • Accessibility
            • Terms of Use
            • Privacy