Canonical vs 301 for index.php
-
Hello, we found recently quite a big error our index.php file had no canonical tag nor was a 301 redirect. So we put a canonical tag to it that it's the main www.examle.com duplicate . Now is there any difference in regards to link juice or Google 301 vs canonical tag ? I read that moz did a 301 from their index php. I understand one difference is that user then can Type in the URL if no 301, but I'm interested about ranking effect of it.
-
The safest and quickest option would be the 301 redirect.
For the cases when that can't be done, there is the canonical option. And of course, make sure that index.php is out of the sitemap.
Hope it helps.
GR. -
Hello,
thanks for the answer. So for raking it would be better to redirect the index.php as i understand? The issue we have is that we use Os-class as our platform, and even if i set a new directory index sitehome.php and make a 301 redirect, our site breaks down and some functionality does not work..
-
Hello,
As Google perspective, there is no difference.
As linkjuice, it's better to redirect with a 301.My experience? (and my opinion) it's more secure and the change is done faster in google's index: 301 redirect.
Best luck.
GR.
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
-
Website is not indexing
Hi All, My website URL is https://thepeopeople.com and it is neither caching nor indexing in Google. Earlier the URL was https://peopeople.com. I have redirected it to https://thepeopeople.com by using 301 redirections. I have checked the redirection and everything else is fine and I have submitted all the URLs in search console also, still the website is not indexing. Its been more than 5 months now. Please suggest a solution for this. Thanks in Advance.
Technical SEO | | ResultfirstGA0 -
Do URLs with canonical tags get indexed by Google?
Hi, we re-branded and launched a new website in February 2016. In June we saw a steep drop in the number of URLs indexed, and there have continued to be smaller dips since. We started an account with Moz and found several thousand high priority crawl errors for duplicate pages and have since fixed those with canonical tags. However, we are still seeing the number of URLs indexed drop. Do URLs with canonical tags get indexed by Google? I can't seem to find a definitive answer on this. A good portion of our URLs have canonical tags because they are just events with different dates, but otherwise the content of the page is the same.
Technical SEO | | zasite0 -
Why is my site not being indexed?
Hi, I have performed a site:www.menshealthanswers.co.uk search on Google and none of the pages are being indexed. I do not have a "noindex" value on my robot tag This is what is in place: Any ideas? Jason
Technical SEO | | Jason_Marsh1230 -
To 301 or not to 301?
I have a client that is having a new site built. Their old site (WP) does not use the trailing / at the end of urls. The new site is using most of the same url names but IS using the /. For instance, the old site would be www.example.com/products and the new site, also WP, will be www.example.com/products/. WordPress will resolve either way, but my question is whether or not to go in and redirect each matching non / page to the new url that has the /. I don't want to leave any link juice on the table but if I can keep the juice without doing a few hundred 301s that certainly wouldn't suck. Any thoughts? Sleepless in KVegas
Technical SEO | | seorocket0 -
301 redirects
Hello. Our site was recently rebuilt, and we switched from using index.php in all the urls to not using it at all. We also changed the names of many of our pages. So the urls have been renamed from "example.com/index.php/old_page_name/" to "example.com/new-page-name/". While we were at it, we changed from "_" to "-" as our word separators in the urls. In the .htaccess file, we have a small block of code that strips out "index.php/" from all requests. This code redirects a request for "example.com/index.php/old_page_name/" to "example.com/old_page_name/" For your information, the code that strips out "index.php/" is: RewriteCond %{THE_REQUEST} ^GET.index.php [NC]
Technical SEO | | nyc-seo
RewriteCond %{THE_REQUEST} !/uSZWTLna/.
RewriteRule (.?)index.php/(.*) /$1$2 [R=301,L] Then we have 301 redirects from "example.com/old_page_name/" to "example.com/new-page-name/" QUESTION 1: Is this two-step redirect approach okay, or would it be better to skip the separate index.php stripping code and simply have 301 redirects that include "index.php" in the urls? QUESTION 2: Will we lose some of the benefit of the links that have to pass through a 301 redirect? QUESTION 3: We have 50 or so redirects. Will this affect performance of the site? How many redirects does it take to start affecting performance? Thank you!0 -
301-redirect
Hi My website is fairly new and i wasnt aware of the difference btw 'website.com' and 'www.website.com' when i started up. It doesnt matter which one i use as long as i am consistent right ? Most of my ingoing links are to mainpage on 'website.com'. I have som ingoing links to 'www.website.com' but also some to 'www.website.com/brandname'. is it enough to 301-redir 'www.website.com' to 'website.com' or does it need to be done on several levels ? I need to have someone do the redirect for me - how can i check its working when its done ? Dan Lærum
Technical SEO | | danlae0 -
Rel canonical with index follow on query string URLs
Hi guys, Quick question regarding the rel canonical tag. I have lots of links pointing at me with query strings and previously used some code to determine if query strings were in the URL and if they were then not to index that page. If there weren't query strings then the page would be indexed and followed. I assume I can now use the rel canonical tag on each of these pages so the value goes to the proper URL minus any query string. However do I need to have the rel canonical tag above the index, follow tag on the page? So URL is site.com/page.html?ref=ABC meta robots is "index, follow" Rel canonical is "site.com/page.html" Does the order of the meta robots and canonical tag matter? Thanks in advance!
Technical SEO | | panini0 -
Did I implement the Canonical Correctly?
Hello, I am trying for the first time to implement a canonical redirect on a page and would really appreciate it if someone could tell me if this was done correctly. I am trying to do a canonical redirect: -from http://www.diamondtours.com/default.aspx -to http://www.diamondtours.com/ As you will see in the source code of the default.aspx page, the line of code written is: <link rel="canonical" href="http://www.diamondtours.com" /> Is this correct? Any guidance is greatly appreciated. Jeffrey Ferraro
Technical SEO | | JeffFerraro0