Our clients Magento 2 site has lots of obsolete categories. Advice on SEO best practice for setting server level redirects so I can delete them?
-
Our client's Magento website has been running for at least a decade, so has a lot of old legacy categories for Brands they no longer carry.
We're looking to trim down the amount of unnecessary URL Redirects in Magento, so my question is:
Is there a way that is SEO efficient to setup permanent redirects at a server level (nginx) that Google will crawl to allow us at some point to delete the categories and Magento URL Redirects?
If this is a good practice can you at some point then delete the server redirects as google has marked them as permanent?
-
Yes, there is a way to set up permanent redirects at the server level (nginx) that Google will crawl to allow you to delete the categories and Magento URL redirects at some point.
Here are the steps:
-
Open your nginx configuration file.
-
Add the following code to the file:
location /old-category {
redirect 301 /new-category;
}
Note:- Replace /old-category with the old URL of the category and /new-category with the new URL of the category. -
Save the file and restart your nginx server.
Once you have done this, Google will crawl the new URLs and update its index accordingly. You can then delete the old categories and Magento URL redirects.
.
Yes, it is a good practice to set up permanent redirects at the server level. This will ensure that users and search engines are always directed to the correct page, even if you make changes to your website's structure in the future.You can delete the server redirects once Google has indexed the new URLs. However, it is important to wait a few weeks to make sure that Google has had time to crawl and index the new pages.
.
Here are some additional tips for setting up permanent redirects at the server level:- Use the correct HTTP status code. For permanent redirects, you should use the 301 Moved Permanently status code.
- Make sure that the redirects are consistent. All redirects for a particular page should point to the same new URL.
- Test the redirects to make sure that they are working properly.
You can ensure that your website's redirects are SEO efficient and that they will not cause any problems for your users or search engines.
Warm Regards
Rahul Gupta
Suvidit Academy -
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Over Optimised Magento Pages
We are working on a clients Magento site and we've added new copy which has a decent keyword density which is in line with best practice. When we run it through Moz we are getting a Key Word Stuffing alert saying the page has 27 keywords, where we can only see about 11. This is the page https://www.greatbeanbags.com/bean-bag-cushions The client is pushing back saying the page must have already been optimised before as our new copy has triggered the stuffing alert. But my guess is the page was already stuffed but buy some Magento code we can't see. Any ideas? #magento #Keyworddensity
Content Development | | Marketing_Optimist0 -
302 redirects in Magento, trying to fix
Hi all, I'm assigned a site in Magento. After the first craw, we found almost 15k 302 redirects. A sample URL ends with this /stores/store/switch/?SID=qdq9mf1u6afgodo1vtvk0ucdpb&___from_store=default&___store=german&uenc=aHR0cHM6Ly9qdWljeWZsdXRlcy5jb20vP19fX3N0b3JlPWdlcm1hbg%2C%2C And they are currently 302 redirecting to the homepage as well as other main pages and also product pages it seems. Some of these point to account pages where customers log in. Probably best for me to de-index those so no issues there. But I'm worried about the 302 redirects to public pages. The extension we have installed is SEO Suite Ultimate by MageWorx. Does anyone here have experience here specifically and how did you fix it? Thanks, JC
Technical SEO | | LASClients0 -
What IS SEO FRIENDLY BEST PRACTICE FOR URLS FILTERED 'TAGGED'
EX: https://www.STORENAME.com/collections/all-deals/alcatel– Tagged "Alcatel", when I run audits, I come across these URLS that give me duplicate content and missing H1. This is Canonical: https://www.STORENAMEcom/collections/all-deals/alcatel Any advice on how to tackle these I have about4k in my store! Thank you
Technical SEO | | Sscha0030 -
Hi Mozers, is the AMP project is supposed to be an SEO factor on mobile platforms? Also, can it be used on ecommerce sites such as Magento or Shopify as well? Thanks!
It stands to reason that Google will favor early adopters of Accelerated Mobile Pages, but it seems heavily geared toward news publishers so far. What about regular Wordpress sites, or ecommerce sites like Shopify, should AMP be pursued on that type of CMS?
Technical SEO | | CalamityJane771 -
How can i do SEO For Ecommerce site
I am doing SEO for my WP blog but now I am starting my recently launch an eCommerce site where I am selling electronics products. I want to know how can I do the SEO so at least I can top 10 position for my google India. Second how can i avoid duplicate content about copying manufacture contents. Please help
Technical SEO | | chandubaba0 -
Which URL structure holds the best SEO value?
Hello Community! We are rewriting URLs to better rank and provide better visual usability to our visitors. Would it be better to serve a URL that looks like this: www.domain.com/category-subcategory or www.domain.com/category/subcategory Please note the slight difference--the 2nd URL calls out a category that has a subcategory under it. Would it give us more value? Does it make a difference? Thanks in advance!
Technical SEO | | JCorp0 -
Does posting an article on multiple sites hurt seo?
A client of mine creates thought leadership articles and pitches multiple sites to host the article on their site to reach different audiences. The sites that pick it up are places such as AdAge and MarketingProfs and we do get link juice from these sources most of the time. Does having the same article on these sites as well as your own hurt your SEO efforts in any way? Could it be recognized as duplicate content? I know the links are great just wondering if there is any other side effects especially when there are no links provided! Thank you!
Technical SEO | | Scratch_MM0 -
Is it better to delete web pages that I don't want anymore or should I 301 redirect all of the pages I delete to the homepage or another live page?
Is it better for SEO to delete web pages that I don't want anymore or should I 301 redirect all of the pages I delete to the homepage or another live page?
Technical SEO | | CustomOnlineMarketing0