by keif on August 15, 2008
When you’re developing a site you may find the need to change your pages around. Maybe you didn’t plan it well, maybe you reushed it to production, maybe you’re doing a friend a favor because they were handed a shoddy job by another developer.
Hell, maybe you read this post about dashes and are converting your pages from underscores.
How can I redirect a page and not hurt my SEO?
What we want to do is called a 301 redirect - which means “moved permanently” like I did from my last college apartment. You would, too, if you were there.
The code to do a redirect:
http://www.webconfs.com/redirect-check.php
- 300 multiple choices (e.g. offer different languages)
- 301 moved permanently - The SEO Friendly option!
- 302 found (e.g. temporary redirect)
- 303 see other (e.g. for results of cgi-scripts)
- 307 temporary redirect
A coworker and I were discussing whether or not dashes are applicable in domain names - from earlier research, it seems Google has some specific issues when it comes to dashes “-” and underscores “_”.
ikeif_blog is the same as ikeifblog (note the _underscore_!)
That’s not going to do me any SEO favors. The fix is easy enough, fortunately, and luckily WordPress does this by default!
ikeif-blog is read as ikeif blog! (note the -dashes-!)
This includes your file names, image file names, page names, etc.
Why the _underscore_?
Our friend the _underscore_ is left over from earlier coding days and *nix systems. From what I’ve been able to gather, it’s not a space is because of programming functions like mysql_affected_rows in PHP, and many older C functions, pre Hungarian notation.
It just translated to the web as an extension of such. That and it kind of makes sense - keith_baker is more like keith baker visually, and keith-baker is like keithbaker. Got that? Google decided that -dashes- were more SEO friendly, and because Google is “the big one” we’re stuck following their obscure rules, and I’m forced (forced!) to research them ;). Is there a grammar lesson in there? May be!
What about periods?
Now we’re down to talking about keywords, and this could be beneficial to stores - yoga-pants.myyogastore.com is better than myyogastore.com - but the debate is open if yogastore.com/yoga-pants is a better alternative still!
The only danger in this,is you don’t want a convuluted or crowded domain name - then it starts to look spammy. Imagine if my domain was ikeif-blog-seo-mootools-jquery-nigerian-scams.com? We also start to make it a difficult site to remember! However, if you like owning domains, it might be possible to benefit from the keyword rich domain and include a 301-redirect to your actual site (if you have more detail, pass it on!)
As a developer and an enthusiast of metrics and media, it’s handy to help flesh out your numbers and “weed yourself out.” Numbers - especially metrics - can help define success or failure of campaigns.
Why would I filter myself?
Why should you neglect yourself? Ever number counts, right? Well, because as a developer (or author, or editor, or paranoid owner) you can skew your metrics numbers by visiting, testing, reloading, hitting the page again and again - throwing off all your numbers. You need unadulterated materials to work with - so at launch when all the employees are visiting that cool new micro site, you know that those million visits were filtered out, which makes the million other visits a lot more relevant.
How to: filter by IP address
Google makes it incredibly easy - you just need to follow a few basic steps.
- Collect the IP addresses you need blocked (i.e. the network you want blocked).
- Log in to Google Analytics and select “edit” under profile, in the same row as your site.

Google Analytics Dashboard Snap-shot
- Go to the section ‘Filters applied to profile’ and select ‘+Add Filter.’
- For this example we want to choose ‘Exclude all traffic from an IP address’
- Enter the IP address(es) you collected, and in true coders fashion, we are going to ‘escape’ the ‘.’ using a backslash - like xxx\.xxx\.xx\.xx
How to: filter by domain
Working on a recent project, I noticed that their hits were skyrocketing - due to the massive amounts of hits from my testing (and their testing, and QA). They had no filters set up on their development site!
As a developer, this should be standard practice - or, if you have a metrics person to work with, have them set up the filter for you. You don’t want to “comment out” the analytics code - this can cause you to forget to uncomment it, or worse case, find another developer has deleted the un-used code (and if you don’t have a subversion repository, you could lose whatever custom code was being used). Fortunately, it’s just as easy to filter out your test domains - On step four, you just select ‘Exclude all traffic from a domain’ and enter it in - a la ‘dev.test.com.’