What are the impact of doing URL Rewriting instead of 301 redirections whille optimizing a blog?
-
In WordPress, with the ALL In ONE SEO pluggingm we've optimze the permalinks to show more keewords in the URL'. What can be the impact?
-
Hi Alexandre,
You will need to look at the code in the .htaccess file generated by All in One SEO to see whether the plugin is just using URL rewriting or creating 301 redirects. As far as I am aware, that particular plugin does not have an option to manually stipulate when you wish to create a 301, but the only sure way is to check the code.
You will need to go into your wordpress /blog directory and download the .htaccess file, then open it in a text editor (like notepad). This is a separate .htaccess file, specifically relating to what happens within your wordpress installation.The one in the root folder for your site will not tell you what you are wanting to know.
I don't use All In One SEO as I prefer the Yoast plugin, but typically, what you might expect to see is code that looks something like this:
BEGIN WordPress
<ifmodule mod_rewrite.c="">RewriteEngine On
RewriteBase /blog/
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /blog/index.php [L]</ifmodule>END WordPress
The key to identifying whether the plugin is using standard URL rewrites or creating a 301 Redirect is to look at the very last part of the Rule - the part that is enclosed in square brackets [ ]
A plain vanilla flavored standard URL Rewrite Rule will end with [L]
If the Rule is creating a 301 (Permanent) Redirect, it will end with [R=301,L]
and for a 302 (Temporary) Redirect, it will end with [R=302,L]
As far as your question, which I understand to be asking essentially, "what is the difference" between the two:
-
A standard URL Rewrite is simply instructing the server that any request for a certain URL should be served a different URL. As far as the search engine is concerned, nothing changes. It is simply used to change the ugly URL to a pretty URL (in your case one that contains the keywords you want).
-
A 301 redirect serves the alternative URL, but also sends a signal to the search engine that the URL requested has been permanently replaced with the one that is served. This indicates to the search engine that the requested URL should be removed from the index and replaced with the URL that is served. A 301 redirect also signals to the search engine that most of the link value being passed to the requested URL should now be passed to the URL that replaces it in the index.
Hope that helps,
Sha
-
-
Hi Alexandre,
You will need to look at the code in the .htaccess file generated by All in One SEO to see whether the plugin is just using URL rewriting or creating 301 redirects. As far as I am aware, that particular plugin does not have an option to manually stipulate when you wish to create a 301, but the only sure way is to check the code.
You will need to go into your wordpress /blog directory and download the .htaccess file, then open it in a text editor (like notepad). This is a separate .htaccess file, specifically relating to what happens within your wordpress installation.The one in the root folder for your site will not tell you what you are wanting to know.
I don't use All In One SEO as I prefer the Yoast plugin, but typically, what you might expect to see is code that looks something like this:
BEGIN WordPress
<ifmodule mod_rewrite.c="">RewriteEngine On
RewriteBase /blog/
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /blog/index.php [L]</ifmodule>END WordPress
The key to identifying whether the plugin is using standard URL rewrites or creating a 301 Redirect is to look at the very last part of the Rule - the part that is enclosed in square brackets [ ]
A plain vanilla flavored standard URL Rewrite Rule will end with [L]
If the Rule is creating a 301 (Permanent) Redirect, it will end with [R=301,L]
and for a 302 (Temporary) Redirect, it will end with [R=302,L]
As far as your question, which I understand to be asking essentially, "what is the difference" between the two:
-
A standard URL Rewrite is simply instructing the server that any request for a certain URL should be served a different URL. As far as the search engine is concerned, nothing changes. It is simply used to change the ugly URL to a pretty URL (in your case one that contains the keywords you want).
-
A 301 redirect serves the alternative URL, but also sends a signal to the search engine that the URL requested has been permanently replaced with the one that is served. This indicates to the search engine that the requested URL should be removed from the index and replaced with the URL that is served. A 301 redirect also signals to the search engine that most of the link value being passed to the requested URL should now be passed to the URL that replaces it in the index.
Hope that helps,
Sha
-
-
I'm not 100% familiar with all that ALL IN ONE SEO PACK is doing there, but usually when you use mod_rewrite (most commonly that I've seen amongst SEO's to rewrite to 'www'), it IS a 301 redirect.
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
-
Should I resubmit a 301 redirected domain in Webmaster Tools
We recently switched over a .com site to a new server. The .com site had a .co.uk domain redirecting to it previously, but when the switchover happened, the .co.uk was forgotten about. We have now realised what has happened, but not before taking a hit with our rankings. The .co.uk is still indexed in Google and now that we have sorted the redirects they are pointing to the right places. My question now; is there anything further I need to do? I know that the .co.uk will soon be removed from the SERPs, but I just want to make sure I haven't forgotten anything.
Technical SEO | | Ben_Malkin_Develo0 -
Canonicals & 301 Redirects to new Domain
We will be changing our domain name soon and I want to make sure I'm not painting myself into a corner. Of course, I want to transfer as much link equity as possible. Question #1: Do I need to define a canonical from the old domain to the new domain? Question #2: Do I also need to put 301s in place on the pages with link equity, or is there a way to apply 301s across the entire site on all pages? Any input would be appreciated greatly! Thanks!
Technical SEO | | BVREID0 -
301 redirect chains
Hi everyone, I've had my site for a while now and have changed the structure a number of times. I'm confident my 301's work well and am not concerned about dead ends on my site. My question is, is there a way to find 301 redirect chains? i.e. can I export my link data from webmaster tools and run it through some software that tells me how many steps my 301's are taking to get to the final page? I don't know for sure that there are long 301 chains in my link structure, but I have a suspicion and it's very hard to check by going through them manually. Thanks in advance Will
Technical SEO | | madegood0 -
Simple 301 redirect a subfolder to another subfolder
Hi, I have a number of sub-folders that I have to move, each of which contains a number of files. subfolder A has files a, b & c subfolder B has files d, e & f
Technical SEO | | aactive
subfolder C has files g, h & i A, B & C folders need to be X, Y & Z Will the following work? RewriteRule ^subfolder-A/* http://www.domain.com/subfolder-X/ [R=301,L]
RewriteRule ^subfolder-B/* http://www.domain.com/subfolder-Y/ [R=301,L]
RewriteRule ^subfolder-C/* http://www.domain.com/subfolder-Z/ [R=301,L] will this result in visitors to http://www.domain.com/subfolder-B/f.html being redirected to http://www.domain.com/subfolder-Y/f.html? All on the same domain. in reality we are talking hundreds of sub folders and thousands of files so we don't want to have to reference every file individually in the htaccess. Thanks0 -
Apache Rewrite Verse Redirect
I put in a request with my IT team to implement some 301 redirects. We recently launched a major redesign and there multiple version of some pages with different URLs. They asked why they could not do Apache Rewrites, so it was not necessary to return an HTTP header. I know Google's Webmasters best practices is to use 301 redirects. I am not familiar with the technical aspects of Apache et al. Are there advantages to using a rewrite? Thanks
Technical SEO | | SuperMikeLewis0 -
Should we 301 redirect our old domain to the new domain
We have a product that when started was under the domain appnowgo.com. We've since changed the name and the domain is now knackhq.com. The latter domain doesn't rank nearly as well as the former for many of the keywords we are targeting. For example... "online database builder" and "web app builder" are two of those keywords. Obviously having app in the domain is not a bad thing but it is our old name. The question is, should we 301 the appnowgo.com domain to knackhq.com? Or should we use that better rank and just link users to knackhq.com from the appnowgo.com site until we can increase our ranking for knackhq.com? We don't plan to update the content on appnowgo.com anymore and we obviously don't want to drop off rank if at all possible. Thanks! Eric
Technical SEO | | sitestrux0 -
301 redirect
Hi All, I have just completed a 301 redirect on my site http://www.klinehimalaya.com and I was just starting a new campaign on SEOmoz and I got this message: Roger has detected a problem:
Technical SEO | | gorillakid
We have detected that the domain www.klinehimalaya.com and the domain klinehimalaya.com both respond to web requests and do not redirect. Having two "twin" domains that both resolve forces them to battle for SERP positions, making your SEO efforts less effective. We suggest redirecting one, then entering the other here. My only other question, is my .htaccess codeing correct and how long will it take to show it is correct in SEOmoz and online? All ".htaccess" code: AddHandler php-stable .php
**_Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_HOST} !^www. [NC]
RewriteRule ^ http://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301] RewriteRule (.*).html$ /$1.php [R=301,L]_** Lastly, I have recently changed all of my files from .html to .php is this going to hurt my SEO and is the code "RewriteRule (.*).html$ /$1.php [R=301,L]" going to fix the issue by redirecting the .html links to the .php pages? Any suggestions or help appreciated. Paul.0 -
URL rewriting causing problems
Hi I am having problems with my URL rewriting to create seo friendly / user friendly URL's. I hope you follow me as I try to explain what is happening... Since the creation of my rewrite rule I am getting lots of errors in my SEOMOZ report and Google WMT reports due to duplicate content, titles, description etc For example for a product detail, it takes the page and instead of a URL parameter it creates a user friendly url of mydomain.com/games-playstation-vita-psp/B0054QAS However in the google index there is also the following friendly URL which is the same page - which I would like to remove domain.com/games-playstation-vita/B0054QAS The key to the rewrite on the above URLs is the /B0054QAS appended at the end - this tells the script which product to load, the details preceeding this could be in effect rubbish i.e. domain.com/a-load-of-rubbish/B0054QAS and it would still bring back the same page as above. What is the best way of resolving the duplicate URLs that are currently in the google index which is causing problems The same issue is causing a quite serious a 5XX error on one of the generated URLs http://www.mydomain.com/retailersname/1 - , if I click on the link the link does work - it takes you to the retailers site, but again it is the number appended at the end that is the key - the retailersname is just there for user friendly search reasons How can I block this or remove it from the results? Hope you are still with me and can shed some light on these issues please. Many Thanks
Technical SEO | | ocelot0