How to fix duplicate product URLs in Magento?

Member

by maci , in category: SEO , 3 days ago

How to fix duplicate product URLs in Magento?

Facebook Twitter LinkedIn Telegram Whatsapp Pocket

1 answer

Member

by elliott , 2 days ago

@maci 

Duplicate product URLs in Magento can create issues for SEO and confuse customers. Here's how you can fix and manage duplicate product URLs:

1. Enable Canonical URLs

Magento allows you to set canonical URLs which help search engines understand the preferred version of a page.

  • Magento 2: Go to Stores > Configuration. In the left-hand menu, select Catalog under the Catalog section. Expand the Search Engine Optimization section. Set Use Canonical Link Meta Tag For Products to Yes. Save the configuration.


Canonicals will help tell search engines which version of the URL to consider as the main one, which can greatly help in avoiding duplicate content issues.

2. URL Rewrites

Magento uses URL rewrite rules to manage URLs for its products, categories, and CMS pages.

  • Check for active URL rewrites: Go to Marketing > SEO & Search > URL Rewrites. Here, you can see all URL rewrites and make adjustments if needed.

3. Check Product URL Key

Ensure that each product has a unique URL key. Sometimes duplicates can occur if URL keys are not unique.

  • Edit URL Key: Navigate to Catalog > Products. Edit a product and go to the Search Engine Optimization section. Ensure that the URL Key field is unique.

4. Remove Old URL Rewrites

Old URL rewrites can sometimes cause duplicate URL issues.

  • Delete old URL rewrites if they are not needed: Go to Marketing > SEO & Search > URL Rewrites. Search for and delete unnecessary duplicates.

5. Examine Custom Modules and Extensions

Some third-party modules and extensions may create duplicate URLs. Verify their configuration and settings to ensure they aren't causing conflicts.

6. Check .htaccess or nginx.conf

In some cases, server configuration files like .htaccess (for Apache) or nginx.conf could be contributing to URL duplication issues. Verify that there are no conflicting directives that might be causing this.

7. Implement 301 Redirects

If you find old duplicated URLs still accessible or crawling errors in Google Search Console, implement 301 redirects to clean them up.

8. Clear Cache and Reindex

  • Once you've made changes, ensure you clear the cache and reindex to apply changes throughout: Go to System > Tools > Cache Management. Clear relevant caches. Reindex data by going to System > Tools > Index Management and selecting indexes to reindex.

9. Monitoring and Maintenance

Continuously monitor your Magento store through tools like Google Search Console to detect any crawling issues, including duplicated URLs.


By following these steps, you should be able to effectively manage and resolve issues with duplicate product URLs in Magento. Ensure you frequently monitor and maintain your SEO settings to avoid future problems.