1

I'm learning to use IIS 7 but I don't understand how I can make my website available through a domain.

I have a domain as example I will call it www.test.com I have made a website in IIS, running on port 80 and can be viewed by typing the IP of the server in the address bar of my browser.

So if I type www.test.com in the address bar how do I make my IIS website show up, without a redirect of course, I don't want users to see the IP in the address bar.

Tom O'Connor
  • 27,480
  • 10
  • 73
  • 148
bk207
  • 173
  • 1
  • 2
  • 9

2 Answers2

6

You need to buy a domain name from a registrar. Then you tell them to set up the DNS for that domain so that there's an A record which specifies that the domain name maps to the IP address for your server.

You can't use "test.com" unless you own it, because you won't be able to edit the DNS records for "test.com".

So once you've got your domain name bought, then you can configure DNS.

Note: I don't work for 123-reg, but the top hit from google is GoDaddy, and they're appalling.

Tom O'Connor
  • 27,480
  • 10
  • 73
  • 148
  • Oke, i will try that. First i will contact my domain provider. Thx – bk207 Apr 02 '12 at 13:18
  • He can use test.com after adding it in `host` file.. – user71823 Apr 02 '12 at 18:00
  • @SachinShekhar It's a bit of a bugger to tell all your potential visitors to do that though. DNS is a far better way to do it. – Tom O'Connor Apr 02 '12 at 19:33
  • @Tom :) No.. no.. no.. I didn't mean to suggest this for live production site. As he is learning to use IIS 7, he can use `host` file based solution. Its free and quick. – user71823 Apr 02 '12 at 19:39
1

Tom O'Connor's answer is correct if your talking about making your website publicly available, but if you just want the website to be available inside your domain, you do not need to do this.

Assuming your using windows, you will need to open DNS on your domain controller and inside Forward Lookup Zones find the Zone name of your domain, go into this folder and create a new host filling in the IP of the IIS server and a host name. So for example, if your domain zone is called test.com, and you gave the host a name of website, users could access your site using http://website.test.com

Tom O'Connor
  • 27,480
  • 10
  • 73
  • 148
boburob
  • 1,174
  • 8
  • 23