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 want my server to forward ALL domain requests to a single page without having to create any entries in httpd.conf or create a zone file. The page that is forwarded to will handle the request and serve up the results.

eg: I register at lets say godaddy (shudder) add an A record pointing to my server

When a user visits, the a record leads them to the server, I now want the server to show them to a certain page without having to have any record of on the server.

How on earth would I go about doing this??


share|improve this question

migrated from Aug 17 '12 at 16:34

This question came from our site for professional and enthusiast programmers.

Doesn't apache do this by default if you don't set up any virtual hosts? What behavior are you seeing instead? – Wooble Aug 16 '12 at 12:21
which web server do you use? – oldmonk Aug 16 '12 at 12:23
using apache right now i just see the browsers 'unable to find message' – Umut Aug 16 '12 at 12:25
Are you sure your request is really being directed to your server? If you do a ping on the machine running the browser, does this ping show you the address of your web server? @Umut – alk Aug 16 '12 at 14:58

So I'm guessing you have no ability to modify the actual Apache configuration given that you have said:

without having to have any record of on the server

So what level of access do you have? if you have the ability to use .htaccess then you could potentially use mod_rewrite (assuming mod_rewrite is available on the Apache server):

RewriteEngine On

RewriteCond %{HTTP_HOST} ^(www\.)?example\.com [NC]
RewriteRule ^(.*)$ [R=301,L]

Hope this helps.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.