Alan Rabinowitz

    All posts by Alan Rabinowitz
    • 301 redirects tutorial

      301 Redirects & Canonical URL Tutorial

      Test Your Redirects with Our Redirect Checker Tool:

      How to use canonical and server-side redirects for SEO

      When you move a file on your server you want to be certain that you pass the proper redirect directive to the browsers and more importantly, the Search Engines. The 301 redirect is the only redirect we recommend for anyone to use without advanced knowledge of using redirects. 302 redirects are actually used by SEO’s for some specific reasons such as moving domain names from an old domain.com to a new domain.com

      Apache | ASP | ASP.NET | Windows IIS | Coldfusion | Sun

      301 Redirects & Canonical Redirects for Apache

      This is done on the invisible file named “.htaccess” this file is located in the root of your Web Server.

      See how to Force all Pages to https below…

      For a single page redirect (NEVER use a 302 make sure it says either “Permanent” or “301” in the file if it doesn’t it will pass a 302 by default:

      redirect 301 /old-file-name-html http://www.yourdomain.com/new-file.html

      or

      redirect permanent /old-file.html http://www.yourdomain.com/new-file.html

      Notice all that is needed is one space between the old path and the new URL. The new URL must contain an Absolute URL: meaning it uses http://www.yourdomain.com/yourfile.html. If there is a space in the file name use %20 otherwise it will not work, you can only leave one space and that is between the old file path and the new url. Here is an example:

      /old%20file.html http://www.yourdomain.com/new-file.html

      Apache Server Canonical Redirect
      (non-www to www):

      This should always be done as some search engines do not properly understand the difference and may count it as a duplicate page, additionally if you use domain.com/index.html or domain.com/index.php the Search Engine might get lost. Since Google is the most popular Search Engine, it also happens to be a bit archaic in its handling of canonical issues and redirects. What Google will see as the same page duplicated on your site (In reality it’s all the same page).

      domain.com
      domain.com/
      www.domain.com/
      www.domain.com
      domain.com/index.html
      www.domain.com/index.html

      Since Google favors penalties over relative content you need to make sure you NEVER link to your home page as “index.html” or any other file extension. The automated factors of the Google algorithm would hurt your rankings without warning assuming that you have a higher potential of spam from duplicate content. Google generally does not notify webmasters of penalties, so you could be spending years trying to resolve an issue like this. Make all your links Absolute (Full URL) at least to your home page, so any link on your site should always link to “http://www.yourdomain.com/” be sure to use the trailing slash as some servers will pass a redirect to the trailing slash if you do not, and this will be a 302 redirect. This is a known issue on WebStar Server, an old Mac Platform web server that has no redirect capabilities.

      ALWAYS:
      http://www.yourdomain.com/
      NEVER:
      http://www.yourdomain.com/index.html -Not direct to the domain.
      http://www.yourdomain.com – No Trailing Slash

      Now for the .htaccess canonical redirect for the NON-www. to the www.

      RewriteEngine On
      RewriteCond %{HTTP_HOST} ^domain\.com
      RewriteRule (.*) http://www.domain.com/$1 [R=301,L]

      NOTE: Some Versions of Apace require an extra line or two of code for SymLinks and a different structure of the rewrite rule as follows:

      RewriteEngine On
      Options +FollowSymlinks
      RewriteBase /
      RewriteCond %{HTTP_HOST} ^domain\.com$ [NC]
      RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]

      To Move To a NEW Domain and redirect both www and non-www versions:
      (This is a change of address for a domain. Old Domain to New Domain 301 Redirect)

      RewriteEngine on
      Options +FollowSymlinks
      RewriteBase /
      RewriteCond %{HTTP_HOST} ^domain\.com [NC,OR]
      RewriteCond %{HTTP_HOST} ^www.domain\.com [NC]
      RewriteRule ^(.*)$ http://www.NEW-domain.com/$1 [L,R=301,NC]

      A More advanced version will even allow you to 301 your IP address and any subdomain:

      RewriteEngine On
      RewriteCond %{HTTP_HOST} .
      RewriteCond %{HTTP_HOST} !^www\.domain\.com
      RewriteRule (.*) http://www.domain.com/$1 [R=301,L]

      The above code will 301 your non-www to your www, as well as redirect your IP address as a 301 to your www.

      For IP Redirection Use:

      RewriteCond %{HTTP_HOST} ^12\.34\.567\.890
      RewriteRule (.*) http://www.domain.com/$1 [R=301,L]

      For www to non-www:

      RewriteEngine on
      RewriteCond %{HTTP_HOST} ^www\.domain\.com [NC]
      RewriteRule (.*) http://domain.com/$1 [R=301,L]

      For Hosting on Certain Servers:

      Godaddy .htaccess use:

      RewriteEngine on
      rewritecond %{http_host} ^domain.com [nc]
      rewriterule ^(.*)$ http://www.domain.com/$1 [r=301,nc]

      When using the www. for Godaddy use:
      RewriteEngine on
      rewritecond %{http_host} ^www\.domain.com [nc]
      rewriterule ^(.*)$ http://www.domain.com/$1 [r=301,nc]

      In the above we removed the ! that we use on other hosting systems, also note the use of capital and lowercase where it would appear as: RewriteCond %{http_host} !^www\.domain.com [nc]

      To redirect your http pages but NOT your https pages use:
      Say for instance, your secure certificate was not created as www.domain.com, but was instead issued as domain.com then you would need to use the following and be sure to combine this with ABSOLUTE links (absolute links use the full URL), or you may unintentionally cause duplicate https and http paths.

      RewriteCond %{SERVER_PORT} ^80
      RewriteCond %{HTTP_HOST} ^domain\.com
      RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L,QSA]

      To Redirect ALL HTTP pages to HTTPS using a 301: (Force all pages to https)

      RewriteEngine On
      RewriteCond %
      {HTTPS} off
      RewriteRule ^
      (.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
      Additionally some servers require an extra line of code:

      RewriteCond %{HTTPS} off
      RewriteCond %{HTTP:X-Forwarded-Proto} !https
      RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

      For Redirection of a directory to another directory on the same site:
      RedirectMatch 301 ^/old-folder/(.*) http://www.yourdomain.com/newfolder/$1

      You can even use a lower-level directory and redirect to a top-level directory:
      RedirectMatch 301 ^/old-folder/directory(.*) http://www.yourdomain.com/newfolder/$1

      If your pages are dynamic you can use:
      RedirectMatch 301 ^/old-folder/?(.*) http://www.yourdomain.com/newfolder/$1

      To redirect all pages of a directory you no longer need/use (removing /blog/) to the root:
      RewriteRule ^foldername/(.*)$ /$1 [R=301,NC,L]

      301 Redirects & Canonical Redirects:
      Microsoft IIS Web Servers

      To Perform this you need administrative access to the IIS Server Application. If you do not have this then you can do the redirects in ASP or PHP.

      Single Page Redirect:

      1. Open Internet Services Manager then “right-click” on the file or folder you want to redirect to a new page or folder.
      2. Select “redirection to a URL”.
      3. Enter the URL where you want the redirect to go to.
      4. Check the fields: “exact URL entered above” and “A permanent redirection for this resource”.
      5. Click “Apply”.

      PHP 301 Redirect
      This is added to the page that you want to redirect to a new page, it is triggered on the request for the specific page and the file will actually return the redirect.

      Single Page Redirect:

      <?php
      header(‘HTTP/1.1 301 Moved Permanently’);
      header(‘Location: http://www.new-url.com/’);
      ?>

      PHP Canonical Redirect:
      (non-www to www)

      <?php
      if (substr($_SERVER[‘HTTP_HOST’],0,3) != ‘www’) {
      header(‘HTTP/1.1 301 Moved Permanently’);
      header(‘Location: http://www.’.$_SERVER[‘HTTP_HOST’]
      .$_SERVER[‘REQUEST_URI’]);
      }
      ?>

      Redirects & Canonical Redirects for Active Server Pages (ASP)

      Single Page Redirect:
      This is placed on the page you are redirecting and is triggered when someone tries to access the page.

      <%@ Language=VBScript %>
      <%
      Response.Status=”301 moved permanently”
      Response.AddHeader “Location”, “http://www.domain.com/”
      %>

      ASP Canonical Redirect:
      (non-www to www):
      This code should be inserted into a global include file or any script which is executed for every page on the site before the page output begins. If your programmers are using ASP.net and/or they are not using a global file, you need to have them address this issue or perform the Canonical Redirect from the IIS Server Application (as above).

      <%
      If InStr(Request.ServerVariables(“SERVER_NAME”),”www”) = 0 Then
      Response.Status=”301 Moved Permanently”
      Response.AddHeader “Location”,”http://www.”
      & Request.ServerVariables(“HTTP_HOST”)
      & Request.ServerVariables(“SCRIPT_NAME”)
      End if
      %>

      301 Redirects for ASP.NET

      For Single Pages:

      <script runat=”server”>
      private void Page_Load(object sender, System.EventArgs e)
      {
      Response.Status = “301 Moved Permanently”;
      Response.AddHeader(“Location”,”http://www.domainname.com/new-page.aspx”);
      }<…

      Canonical Redirect for ASP.NET (ASPX):

      For ASP.NET you need to do this individually in the Windows IIS Internet Services Manager or Use The ASP Code above in a global file that will process the redirect BEFORE any other processes.

       

      301 Redirects for Macromedia ColdFusion

      Since cold fusion is usually hosted on Windows, Linux, and Sun. The .htaccess and Windows IIS tutorials above will have solutions for the Canonical and redirects. This is for a Single Page Redirect embedded directly into the file:

      <cfheader statuscode=”301″ statustext=”Moved permanently”>
      <cfheader name=”Location” value=”http://www.new-location.com/”>

      301 Redirects for Sun Web Servers

      In order to do this on a SUN platform you have to rewrite the SUN Web Server’s standard action of always using a 302 redirect to always use a 301 redirect. You have to open the obj.conf configuration file and add the following lines below the <Object name=”default”> line:

      <Client code=”302″>
      Output fn=”set-variable” error=”301″ noaction=”true”
      </Client>

      The above will make the SUN webserver to return 301 permanent redirect responses for all redirects. If you only want to use a 301 permanent redirect response for certain URLs or files, you can add the following to the bottom of obj.conf:

      <Object ppath=”path”>
      <Client code=”302″>
      Output fn=”set-variable” error=”301″ noaction=”true”
      </Client>
      </Object>

       

      Top | Apache | ASP | ASP.NET | Windows IIS | Coldfusion | Sun




    • Catching Up on Search in 2012

      Since my last post on search engine market shares in 2008, Google’s dominance in the U.S. and worldwide markets has only risen to even loftier heights. However, with signals in place that 2012 could see once vital Yahoo lose even more ground to Google and Bing, which didn’t yet exist in 2008, it’s worth a look to see how the search engine landscape has changed over the past few years.

      2009: Replacing MSN Search, Live Search, and Windows Live Search, Microsoft launched Bing on June 3, 2009 amid much media fanfare. By the end of 2009, Microsoft/Bing’s market share was 10.7%, representing a growth of approximately 2.7% over the former Microsoft search engines it replaced.

      With Google’s market share growing from 63% to 65.7% over the course of 2009, it became apparent that Bing was pulling users from other smaller search engines, most notably AOL which saw its market share drop a staggering 20% in that year. Yahoo, in comparison dropped less than two percentage points, but was still on the market share’s losing end.

      2010: Looking back at 2010 Q4 market share statistics from around the world, the real runaway story of 2010 was Google which crossed 70% of worldwide searches in 2010 to end the year with a 71% market share. In the U.S., this figure was even higher. Bing held steady at 9.8% of global searches, again at the expense of smaller search engines. Smaller search engines shrank to less than 5% of all search traffic. Yahoo, showing the first signs of real trouble, dropped from a 20% market share to 14.5% to end the year on a disappointing note.

      2011: In 2011, Google surged to an incredible 89.94% market share worldwide at one point, leaving very little of the pie left to its competitors to divide. According to Read Write Web, February 2011 marked the first time Bing overtook Yahoo. That month, Bing outranked Yahoo by a half percentage point. Of course, this seems like peanuts compared to Google, but is still significant.

      2012: Is Yahoo over? The proof may really be in the market share data. Looking at a comparison just between December 2011 and January 2012 finds the once dominant search engine slipping more than 4% in its search share, dropping from 15% to 11% world wide. In comparison, Bing gained a .42% — small gain, but still better than losing a half point.

      Future predictions are calling for the race for solid second place to really heat up this year between Yahoo and Bing. Yahoo currently uses the Bing results and has constantly changed search providers in the past they served Google results. AOL and Ask are both expected to further deteriorate.

      What do you think the future holds for search engines? Will Google continue to reign supreme?

      With Bing’s Social Integration into search paving a new frontier for the Search Engine landscape we will have to see if they can pull some search rank percentages from this new social feature. Considering that Facebook search only searches Facebook profiles, it would be interesting to see if a union of Bing and Facebook with bring competitive market share to the table. Since Google seems to revamp social sites with social circles to try to cut into Facebook’s social share (adding rumors that Google + will help rankings to gain a user-base of marketers buzzing), it would be interesting to see Facebook strike back and enter the Search landscape by either integrating bing or buying a search application.




    • Search Engine Optimization 2009 Trends – Past, Present & Future

      Search Engine Optimization TrendsThis year makes 10 years that I personally have been optimizing sites. That being said it also marks a point where SEO is becoming a flooded market with every Joe Schmoe able to be an SEO professional and every large SEO firm hiring every Tom, Dick, and Harry, not that I do not like large SEO firms, as SEO Image is on its way to being one. Nor does one need 10 years of experience, seeing as I had clients ranking in Top spots in 1999, however, the SERPS were different then and so was SEO.

      So here’s my recap and mini-trend info based on how I see it having 10 years of excessive hands-on experience (Yes, that means I still work on client sites) ranking clients for numerous extremely competitive terms.

      SEO In The late ’90s
      90% on-page SEO 10% link popularity, although most traffic in the ’90s came because we linked and traded links freely with related sites because that was a good percentage of the traffic most sites received then. Less can from search and banner ads were abundant.

      SEO in the Early 2000s
      On-Page SEO making 40% Link Popularity 60% probably more. The dawn of link popularity as being more important than on-page work, which included many sites interlinking and using subdomains. Large firms and companies that had all their client banned for creating interlinked networks that included hundreds of their clients. Also the dawn of shady SEO firms and tactics.

      SEO in the Mid 2000s
      75% Link Popularity about 25% On-Page depending on the industry. The dawn of Social Media sites and people who seem to have endless time to socialize online. Search empowers more businesses and replaces the Yellow Pages in many households. Google triumphs over its competitors.

      SEO In the Late 2000s
      80% link popularity, some cases 90%, about 20% on-page SEO dependent on the industry and the competition. SEO is mainstream and many sites are using it. Link building surges and links become a commodity and are brokered. The PageRank toolbar loses much of its value for ranking purposes but is still in existence for public viewing.

      The Future
      As social media sites get spammy and offer less original content, they may get devalued, after all, if you shopped online this past holiday season you probably found it hard to find retailers under the flood of price comparison sites and blogs that all review the same products. Regional control and browser-based search results (via cookies) will all control the search results (see the next post). Link popularity will still be a heavy practice, but the valuation will make it even more complex as new algorithms and link determination factors will be utilized. On-Page will have more value and site size will be less important. Informational sites may lose value in comparison to exact match sites and sites that are NOT blogs with reviews of everything under the sun. Category (relationship) based search engine optimization will be integrated further and higher valued. Superior conversion based pay per click management will be more important.




    • Google Has 80% of Worldwide Market Share! Total Domination

      Google Search DominanceA report from Hitslink, an analytics firm, states that Google has close to 80% of worldwide search traffic and market share. Those numbers indicate the importance of marketing on Google and should make businesses  consider BOTH SEO and PPC campaigns as viable marketing solutions.

      With new search engines popping up and trying to compete, it seems unlikely that anyone could achieve dominance to this extent or even have a shot at competing with the Google Search World (which I now call the Internet).

      Many businesses approach us looking to try to avoid the cost of PPC by developing a natural campaign. While we do believe it is extremely important to have a natural online presence, there is much to say for a properly managed advertising and Pay Per Click campaign. Many businesses can run successfully with PPC alone. Gaining a presence in both the natural and paid sectors will offer double the exposure. Cap that with strategic advertising on industry related portals and niche sites, and you can have an effective business.




    • What If… Google Buys Yahoo?

      What if…the testing of Google Adwords on Yahoo is really something else? What if Yahoo is trying to help Google determine the value of Yahoo if adwords were to be part of Yahoo. Since Google’s main revenue is Google Adwords, it makes sense to devote multiple avenues to paid search. A Google buyout of Yahoo?

      This would achieve 80% to 90% of all online natural and paid searches, is this really the reason? The control of the Search Industry to one single multiplied giant would almost be, if not, a monopoly on Search. Making a top 10 listing for both natural and paid search twice as valuable.

      Since I read the press release for the new partnership, I have thought from a business perspective. Maybe I am just planting ideas here, but if I owned Google and wanted to monopolize the Search Industry what would I do? Glad I asked, its simple I would buy Yahoo!

      Yahoo is worth more than just a Search Engine in many ways. They capitalize on buying and developing social sites like Yahoo Answers (which beat out Google Answers) and MyBlogLog. Yahoo also has a large email and portal user base to boot.

      Think about it, it would be total domination of Search if Google bought Yahoo! Many people do not remember a few years back when Yahoo did in fact served Google natural results. That partnership however, did add more authority to Google’s leadership in search quality at that point in time when they were only starting to emerge as the leader.

      Why wouldn’t they consider MSN ads if a potential MSN buyout is in the air? The timing does not make $ense. Perhaps there is another potential partnership under way.

      Food for thought is it an SE Conspiracy? Potential new buyout? Marketing Strategy? Battle of the Big Brands?

      –>You decide.



    • This Site May Harm Your Computer

      This Site May Harm Your Computer & Your Mind

      You better think before using popular applications meant for blogs as the core for your business. What happens when Google decides to remove access to your site from the results because your trendy and popular blog application (WordPress in our case) gets hacked without your knowledge.

      Think about it, you invest thousands into marketing and promoting your site via a CMS and Blog application that is so popular, that it constantly needs security updates. Now, your busy managing your business and do not have the time to constantly manage and update the software of the blog, or do not want to because some of the plugins you use do not work on the new version.

      Consider also, that if you are lucky enough to get an email from Google reporting the hack and that your site is blocked, you will be luckier still to get the barrier Google uses removed from your listings in Google in a timely manner. This can cause weeks of traffic lost for using a program. This is just plain old frustrating for any business owner.

      Warning

      Its common sense!

      Is a popular application worth the risk of a potential and “Hopefully Temporary” loss of traffic? Can you live without Search Engine traffic for weeks, months or even years?

      If you’ve never submitted a re-inclusion request with Google then you need to understand the process and the time line as you are likely one of hundreds of thousands of sites (I’m estimating numbers here, and yes, I do believe there are a lot of sites in the queue). A typical re-inclusion; you usually get no response other then a general email stating you will most likely not get a response. You are generally left in the dark for weeks, months and even years with no assistance or the luck of the draw someone fixes your problem, which may not have been a violation. You can be one of many left in the dust, while everyone else seems to do worse than you without any problem. You can go public and call out Matt Cutts and maybe, just maybe, he will be kind enough to respond and help as seen on many blogs that decide publicly screaming is the only way to get attention. I’m still waiting Matt! Please Help!



BEFORE YOU GO... WE GET RESULTS!

    SEO & Reputation Management Services in NYC & Long Island

    We'll Get You Rankings & Improve Your Reputation
    Get Started - 888-736-2667

    X