Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know this is easy with a 301 redirect in the apache config, but I'm looking for a 3rd party service that can do this cheaply or free. I'll be using this to redirect non-www traffic to a www record I've CNAME'ed to an Amazon Elastic Load Balancer hostname.

share|improve this question

closed as off-topic by TomTom, bangal, RobM, kasperd, Michael Hampton Feb 22 at 23:01

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.

    
On Amazon AWS with Route 53 the "correct" way to do this is with an S3 bucket. – Michael Hampton Feb 22 at 23:02

You should make this a HTTP 301 Moved Permanently redirect, as you mention.

Most DNS hosting services have this, so the first place to look would be your current DNS host / DNS service provider. There doesn't seem to be any agreement on what to call this -- GoDaddy seems to call it "forwarding", Gandi calls it "Web Forwarding".

If your DNS service provider doesn't have this, then the simplest solution would probably be to either:

  1. Find a super inexpensive web host like Nearly Free Speech, assign the root @ to this host's IP, and use PHP/.HTACCESS as you mention, or
  2. Switch to another DNS service provider.

.. at least I'm not aware of any (large, reputable) services which just do HTTP redirects without doing something else too, like DNS.

share|improve this answer
1  
NearlyFreeSpeach's UI is insanely unintuitive, and their FAQs don't help. But I've done this successfully by creating a "Site", specifying my naked domain for it on creation (they call it an "Alias"), and SFTPing my .htaccess file to it. Make sure to change the Site's "type" to "static", and NFS only charges for storage, which is practically nothing. – Jonathan Tran Jan 15 '13 at 1:01

Yes - two which are free are arecord.net and wwwizer.com First requires email confirmation and signup second seems better/easier - IP is provided on the homepage.

What I'm still searching for: a free redirect service out there which you can point to via A/CNAME record, and it will allow you to redirect to ANY destination URL!

share|improve this answer

Amazon's Route53 DNS service supports pseudo-A records for an ELB instance (they call them "ALIAS" records).

share|improve this answer

Well... Why don't just add a record like

$ORIGIN domain.com.
@               IN A            1.2.3.4
www             IN A            1.2.3.4

Into your DNS zone file?

share|improve this answer
3  
Because of the Amazon Elastic Load Balancer service, which only supports DNS CNAME's. CNAME's are currently not valid for the @ (2nd level). – Jesper Mortensen Apr 1 '11 at 18:53
    
Thanks. I didn't know it. Will be a lesson for the future. ;) – HUB Apr 4 '11 at 6:54

There now is a free service that can redirect to ANY destination URL by A-record. https://www.301redirect.it

share|improve this answer
    
This almost looks like promotional spam; are you affiliated with that site/service at all? – Castaglia Feb 22 at 18:43
    
Yes it's my site, and I just launched it yesterday. I haven't spammed anywhere. This thread was what I found before I created the service (when looking for a service like this myself), and now I just wanted to let other people find it. Thread is exactly about this, right? – Jimmie Andersson Feb 23 at 20:39
    
As far as I can tell, yes. And it's OK to mention a link to some site like that -- as long as you disclose your affiliation; see the help center docs on this for more info. – Castaglia Feb 23 at 20:54

Not the answer you're looking for? Browse other questions tagged or ask your own question.