Saturday, June 23, 2012

Posted Under:

7 Easy Steps to turn your PC into a Web Server to host your Website

Getting your own Website on Internet these days has become a child's play. You can get a good hosting service at almost negligible cost and your website, it can be designed by Online free templates. But the Fun of Hosting your Website yourself is satisfying. 
It offers you with total power and control over your website, and no crucial data of your website is vulnerable, if you work a bit on your Server's security.

But the Question here is, How to do this? How to actually turn your PC into a Web Server to host your very own Website from Home. So today we will do this, by following these 7 easy steps to turn your PC or Laptop into a working Web server


1. System and Internet Connection


Get a PC or a Laptop, which will serve as your Web Server. For good performance, keep the system dedicated for Web Server only, do not use it for your routine work too. Also, a High speed Internet Connection is required. 



2. Web Server Software


Download and Install a Web Server software from the internet. They are mostly freely available. You can get, XAMPP, WAMP or the Apache HTTP Server
I would recommend to go with XAMPP, because it is an awesome Web Server for Windows Platform, already installed with Php, Apache and MySql.




3. Get a Static IP Address


Most of the ISP(Internet Service Providers) do not provide their regular customers with Static IP addresses, So you will have to ask your ISP to get a Static IP for your Internet Connection. You might have to pay some extra charges for this.

What is Static IP Address ?
Static IP Address is a fix IP Address provided to you by your ISP, which will not change like the usual dynamic IP Addresses. It will provide a unique identity to your Internet Connection over the Web.



4. Activate your Domain Name


In case you do not have a domain name, Get a Domain Name for your Website. You can easily register a domain name (example.com) for your Website using any Domain Registrar. eg : godaddy.com , bigrock.in etc

After getting a Registered Domain Name for your Website, you need to activate your Domain name, or I would say, point it to our Static IP address.

Your Domain Registrar Website will provide you with the Admin Panel of your Website. Where you can add DNS (Domain Name Server) details for your Domain Name.
You just have to add A Records for your domain name, find Where you can do that and fill in your domain's name, and at the place where Destination IP Address is asked, save your Static IP Address.





After saving these details, your Registrar will direct all the users, visiting your domain name (example.com), to your IP Address where, your Web Server will broadcast your Webpage to them.



5. Create a Simple HTML page


In case you have your Website already made, copy its files into the "htdocs" folder of your Web Server. If you do not have it, simply make an HTML page saying "Hello" and save it in htdocs folder under name index.html .

Delete all other files from the htdocs Folder, because they might produce some security errors.




6. Allow PORT 80 access


Windows Firewall sometimes blocks PORT 80, to stop foreign access to your system. So you need to add a rule to your Windows Firewall to allow PORT 80, thereby allowing Internet traffic to access your Web Server.

Follow the following steps :
  • Go to, Control Panel >> System & Security >> Windows Firewall >> Advanced Settings.

  • We now have to save a new Rule for both Inbound and Outbound. Click on New Rule , and add a new Port .

Choose PORT, out of the given options and click on Next.


Select TCP, Specific Local Port and add 80 to the textbox. Click on Next.


 Select Allow the Connection, and click on Next.



After this you will be asked to Add a Name to the rule, Write whatever you wish and click on finish to add this rule. Similarly, add the same rule for Outbound too.


7. Restart your System, and Check the Web Server


You are done with all the work, now you just need to Restart your system and check whether your Web Server is working as per the requirements or it is showing some unwanted error. I hope it won't show up with any error. Just go to your browser, and type in your domain name to access your webpage. 

If somehow, your domain name isn't found, then wait for some time, because Domain Registrar take some time to implement the DNS settings for your domain name.

So this was a very simple tutorial, to turn your Personal Computer into a Working Web Server to host your Website. We would advice you to install a strong AntiVirus to save your system from un-welcomed threats from Internet. 

Also, if your website is a big one, that is it receives a lot of hits daily, you must upgrade your Hardware to some powerful server system with a high speed internet connection.

Such Web Servers are also very useful to test websites while they are still under development. These servers can also be used to share pictures, videos and documents over internet with your family and friends.

If you face any problem doing this, do let us know through your comments. We love hearing from you.





Thanks for Template.