Use of Apache mod_rewrite module for SEO?
-
I'm curious if anyone here running a large, complex, dynamic site has used the Apache server mod_rewrite module to simplify their site's URLs by rewriting them in a standard format.
The chief use of this module for SEO purposes would be to aid in canonicalization and reduce duplicate content. For example, you could easily convert all of you ALL CAPS or MixedCase URLs to lower case, change all "/index.html" URLs to just point to "/", change all word seperators to hyphens, and so on.
Any server-side ninjas out there with stories to tell?
-
If you're looking for truly apache mod_rewrite stories I cannot help, but I have implemented site-wide redirect schemes so that (for example) all URL's are put into Title Case, all folders are redirected to ensure trailing slash, and much more.
It made a big difference and is highly recommended. Our duplicate content (that google wasnt even reporting but that we saw with tools like the IIS SEO toolkit http://www.iis.net/download/seotoolkit) dropped to zero and shortly afterwards our traffic increased as a result of increased keyword ranking almost across the board.
Too many people ignore this.
-
I use Drupal CMS alot for my sites. It provides a simple .htaccess with mod_rewrite ON and examples. Also, if using drupal you can create alot of rules from the admin part (such as url aliases and 301 redirects) rather than in the file itself. So, you dont necessarily have to be a ninja to tweak all these settings.
Also alot of caching is done through mod_rewrite as when you cache the page to HTML and rewrite the path in .htaccess to use html cache when someone requests given url => speeds up the site , because it will not even need to touch a database and go directly to html file with cached data.
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
-
Can cross domain canonicals help with international SEO when using ccTLDs?
Hello. My question is:** Can cross domain canonicals help with international SEO when using ccTLDs and a gTLD - and the gTLD is much more authoritative to begin with? ** I appreciate this is a very nuanced subject so below is a detailed explanation of my current approach, problem, and proposed solutions I am considering testing. Thanks for the taking the time to read this far! The Current setup Multiple ccTLD such as mysite.com (US), mysite.fr (FR), mysite.de (DE). Each TLD can have multiple languages - indeed each site has content in English as well as the native language. So mysite.fr (defaults to french) and mysite.fr/en-fr is the same page but in English. Mysite.com is an older and more established domain with existing organic traffic. Each language variant of each domain has a sitemap that is individually submitted to Google Search Console and is linked from the of each page. So: mysite.fr/a-propos (about us) links to mysite.com/sitemap.xml that contains URL blocks for every page of the ccTLD that exists in French. Each of these URL blocks contains hreflang info for that content on every ccTLD in every language (en-us, en-fr, de-de, en-de etc) mysite.fr/en-fr/about-us links to mysite.com/en-fr/sitemap.xml that contains URL blocks for every page of the ccTLD that exists in English. Each of these URL blocks contains hreflang info for that content on every ccTLD in every language (en-us, en-fr, de-de, en-de etc). There is more English content on the site as a whole so the English version of the sitemap is always bigger at the moment. Every page on every site has two lists of links in the footer. The first list is of links to every other ccTLD available so a user can easily switch between the French site and the German site if they should want to. Where possible this links directly to the corresponding piece of content on the alternative ccTLD, where it isn’t possible it just links to the homepage. The second list of links is essentially just links to the same piece of content in the other languages available on that domain. Mysite.com has its international targeting in Google Search console set to the US. The problems The biggest problem is that we didn’t consider properly how we would need to start from scratch with each new ccTLD so although each domain has a reasonable amount of content they only receive a tiny proportion of the traffic that mysite.com achieves. Presumably this is because of a standing start with regards to domain authority. The second problem is that, despite hreflang, mysite.com still outranks the other ccTLDs for brand name keywords. I guess this is understandable given the mismatch of DA. This is based on looking at search results via the Google AdWords Ad Preview tool and changing language, location, and domain. Solutions So the first solution is probably the most obvious and that is to move all the ccTLDs into a subfolder structure on the mysite.com site structure and 301 all the old ccTLD links. This isn’t really an ideal solution for a number of reasons, so I’m trying to explore some alternative possible routes to explore that might help the situation. The first thing that came to mind was to use cross-domain canonicals: Essentially this would be creating locale specific subfolders on mysite.com and duplicating the ccTLD sites in there, but using a cross-domain canonical to tell Google to index the ccTLD url instead of the locale-subfolder url. For example: mysite.com/fr-fr has a canonical of mysite.fr
Intermediate & Advanced SEO | | danatello
mysite.com/fr-fr/a-propos has a canonical of mysite.fr/a-propos Then I would change the links in the mysite.com footer so that they wouldn’t point at the ccTLD URL but at the sub-folder URL so that Google would crawl the content on the stronger domain before indexing the ccTLD domain version of the URL. Is this worth exploring with a test, or am I mad for even considering it? The alternative that came to my mind was to do essentially the same thing but use a 301 to redirect from mysite.com/fr-fr to mysite.fr. My question is around whether either of these suggestions might be worth testing, or am I completely barking up the wrong tree and liable to do more harm than good?0 -
Menu Structure & SEO
Hi I have been trying to decide whether we need to change our menu structure http://www.key.co.uk/en/key/ We have a lot of subcategories which are not in the menu structure and for SEO I wonder whether its best to have menu drop downs, so if a customer hovers over one category, it will display all the subcategories within this. I am concerned that sub categories we are trying to rank are many levels away from the homepage e.g If you want to find leather office chairs from the homepage, you have to go to the 'More categories' link, then choose seating > office seating > leather office seating. Users need to do a lot of navigating before seeing what we offer. I would prefer if a user could see these options in the menu when they hover over it. Does anyone think this would help SEO or just customer journey? Thank you
Intermediate & Advanced SEO | | BeckyKey0 -
Do Page Anchors Affect SEO?
Hi everyone, I've been researching for the past hour and I cannot find a definitive answer anywhere! Can someone tell me if page anchors affect SEO at all? I have a client that has 9 page anchors on one landing page on their website - which means if you were to scroll through their website, the page is really really long! I always thought that by using page anchors instead of sending users through to a dedicated landing page, ranking for those keywords makes it harder because a search spider will read all the content on that landing page and not know how to rank for individual keywords? Am I wrong? The client in particular sells furniture, so on their landing page they have page anchors that jump the user down to "tables" or "chairs" or "lighting" for example. You can then click on one of the product images listed in that section of the page anchor and go through to an individual product page. Can anyone shed any light on this? Thanks!
Intermediate & Advanced SEO | | Virginia-Girtz1 -
SEO Blow-Up After Site Redesign
I contracted with a local web design firm - a highly recommended firm - to redo my law practice's Wordpress site. The redesign was done in early April. After the redesign I saw a large drop in rankings across all of my keywords, lost internal page rank, and had a big traffic drop. The site is www.toughtimeslawyer.com. There were a couple of issues that contributed to it; but I'm not sure how to rebuild. The internal URL structure changed completely. I wasn't aware of this until the site went live. I didn't have a sitemap for about a week, then the sitemap plugin they used was not very good and showing errors in Webmaster tools. Last week, I replaced it with Yoast's SEO plugin. The biggest problem is that they setup a subdomain old.toughtimeslawyer.com, without asking me or telling me. The subdomain had all of my content on it. It was not blocked with robots.txt; and it is being cached by Google. I just discovered it today, when I was doing something in my cpanel. I assume that this is creating a duplicate content problem with Google. I'm not sure what steps to take to recover. I am especially concerned about the subdomain old.toughtimeslawyer.com and the best want to handle it with the search engines. Thanks in advance, all advice is appreciated. I've been pulling my hair out for the last few weeks over my rankings.
Intermediate & Advanced SEO | | ToughTimesLawyer0 -
SEO Ecommerce Keywords
Hi guys got a question regarding ecommerce seo do you think its a better idea to target more long tail terms and try get links directly to product pages, brand pages and categories. Rather than focus on short keywords that do bring in good traffic but are very broad, i will prob do both, but i would like a second opinion please about other users strategies thanks
Intermediate & Advanced SEO | | Will_Craig0 -
Am I Doing This Wrong? Ecommerce SEO
I ran my site through the SEOMoz On-Page Optimization tool and one of the problems noted was "Keyword Self-Cannibalization" in this case, it was stating I was using the keyword "Board Games" too much. Site in question: http://theboardgamers.co.uk/ The problem being is that every product link contains the word "Board Game" - Which makes sense, but I guess it may look spammy to the SEO world. Would it be best to remove the "board game" part from each internal link and only leave it in the URL structure?
Intermediate & Advanced SEO | | REMOVE560 -
How do you implement dynamic SEO-friendly URLs using Ajax without using hashbangs?
We're building a new website platform and are using Ajax as the method for allowing users to select from filters. We want to dynamically insert elements into the URL as the filters are selected so that search engines will index multiple combinations of filters. We're struggling to see how this is possible using symfony framework. We've used www.gizmodo.com as an example of how to achieve SEO and user-friendly URLs but this is only an example of achieving this for static content. We would prefer to go down a route that didn't involve hashbangs if possible. Does anyone have any experience using hashbangs and how it affected their site? Any advice on the above would be gratefully received.
Intermediate & Advanced SEO | | Sayers1 -
Do any of you regularly use expired domains?
I know there has been discussion on using expired domains in the past. This is not so much a question as to how to do it or whether it works, but rather I would love to see how many of you use this in your backlink strategy. I have a domain in a low to moderately competitive niche that ranks really well, mostly on the power of a couple of expired domains. I bought the domains, created a quick wordpress site and pointed some anchor texted links to the site. It took some time for the expired domains to regain their PR, but when they did, the benefit was great. I'm considering whether I want to do this with another domain of mine. On one hand, it's a relatively inexpensive way to get some good quality anchor texted links. But, on the other hand, something in it feels "immoral" or "sneaky" to me. What do you think?
Intermediate & Advanced SEO | | MarieHaynes0