Where to put 301 redirects in Magento?
-
I will be changing the URL structure in a magento store from "base/category/subcategory/product" to "base/product" which means i have to make over 1000 URL 301 redirects so our old links still work.
Should i put the redirects in a .htaccess file so they stay intact no matter what or should i just put them in with all the other rewrites (in Magento 's URL rewrite manager)?
Thanks
-
Yes I suppose it would check everytime. That said, i have written files with several hundred lines of code and the sites still load really fast even on shared servers which are not the best...
-
Will that in any way slow down the site? Adding thousands of lines of code to the .htaccess file?
Edit: Checked some more, apparently having thousands of redirects in .htaccess file shows things downs, since Apache scans the file each time a new page is opened.
tl/dr: Stick with magento URL rewrites
-
I think either is fine as long as it works. Personally I prefer to writ my own .htaccess files as I then understand exactly what I have done - it feels safer for some reason.
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
-
How do you fix redirect chains and temporary redirects?
Hi, I have a lot of issues popping up with temporary redirects and redirect chains. I'm still confused as to what exactly redirect chains are and I don't know how to find where the "chains" are or how to fix them. I'm having two issues mainly:1. Temporary RedirectsI have around 100 pages on our www.twowayradiosfor.com website that are being flagged as temporary redirects. All of them have one thing in common: they are review pages (basically, when a customer clicks on the Review button to review a certain product, they are redirected to a review page for that product).URL Example: https://www.twowayradiosfor.com/reviewhelpful.asp?ProductCode=CLS1410-COMBO&ID=44&yes=noI went into our website and set any URL containing the following as noindex:/review.aspWill that fix the issue? If yes, will I also need to do that for any URL containing /reviewhelpful.asp?2. Redirect ChainsIt seems like basically every product page on my website has this issue (over 100 pages). Here's an example of one:https://www.twowayradiosfor.com/Motorola-CLS1110-p/cls1110.htmI don't see any broken links on this page or links that redirect to another page that redirects, etc. What is causing this? Is it something on my header bar that is redirecting (since that header bar appears on every page, maybe that is why this issue shows up on a lot of pages)?I am new to Moz and still trying to figure this stuff out. I really appreciate any help. Thanks, Sawyer
Technical SEO | | AllChargedUp0 -
301 Redirecting http to https
In the Moz Site Crawl issue, I was seeing an error that said we were temporarily redirecting our homepage to https URLs. So I changed the code in htaccess to make it 301 redirect but I'm still getting the same error. I implemented it last week and we just had a new crawl yesterday. Here is the new code: RewriteEngine on
Technical SEO | | Heydarian
RewriteCond %{HTTP_HOST} ^heritagelawmarketing.com [NC]
RewriteRule ^(.*)$ http://www.heritagelawmarketing.com/$1 [L,R=301,NC] Does anyone know why I'm still getting 302 redirects? Thanks0 -
Redirect 302 status code to 301 status code
Dear All, According to Mozz crawling report our site (www.rijwielcashencarry.n) have a few medium priority problems. There are 302 temporarly direct which i would like to redirect to 301 (because of the linkjuice). What is the proper way to do this?
Technical SEO | | rijwielcashencarry040
I keep looking for it, but i can't seem to find the right solution. Thanks for your help!0 -
Which way round to 301 redirect?
Hi We have just added a new layered navigation menu to our website. so for example we had Before : www.tidy-books.co.uk/chidlrens-bookcases (this has the seo juice) And Now: http://www.tidy-books.co.uk/childrens-bookcases-book-storage/childrens-bookcases Might be a stupid question but do I redirect the 'now' url to the 'before' url or the the other way round I look forward to hearing your thoughts Thanks
Technical SEO | | tidybooks0 -
301 redirect + new website copy
Hi There, We are currently redeveloping our website and we're rewriting and optimising our many of our service pages. I think I may already know the answer but should we apply 301 redirects from our old services pages to the new versions? The content subject matter will be the same on the new versions, they will just be completely reworded. I would be interested to hear your views. Thanks, Stu
Technical SEO | | Stuart260 -
Creating a Target URL For 301 Redirect in Wordpress
I am confused as to what to put in as the target URL. Is this just a new URL that I must create a name for? I am having trouble finding any answer for this on the internet, just more people asking the same question. I am finally realizing that all the information is found right here at SEOmoz to both learn and ask questions about.
Technical SEO | | lartinos0 -
301 redirect .htaccess problem
Can anyone explain to me why this doesn't work? Redirect 301 /category/diamond-pendants/nstart/1/start/(.*) http://www.povada.com/category/pendants/nstart/1/start/$1 Im trying to replace everything after /start/ and insert it into the new url. Thanks in advance.
Technical SEO | | 13375auc30 -
301 redirect
We have just had an outside SEO agency report on our site: One of things brought up were arounf broken links, and how they class them as broken links. Could any body tell me whether this statement holds true please, as I am not aware of this "Our latest intelligence shows that google are downgrading ranking from sites that feature 301 redirects within the internal link structure". Any help would be greatly appreciated Regards
Technical SEO | | Yozzer0