How to host website on my pc

Asked

Viewed 6,157 times

0

I’m creating a php application with using xampp. I would like to know how to turn my PC into a hosting server, so I can access my application from anywhere. I already tried to access my router admin (D-link Dir-608) created a "virtual server", however, without success, error occurs when trying to access the external ip. Does anyone have any tips or tutorial teaching? Thank you.

1 answer

3

Use the software NO-IP. Register on the site, choose an external host name, example my-home.sytes.net, install the software on your computer and access the software with your beliefs.

Once accessed and logged in to the software, you will need to configure your router to route a certain traffic to your machine. In the case of a lodging, the important doors would be the 80 for access via HTTP, and 443 for access via HTTPS. I believe that just setting the 80 is enough for your case.

To accomplish this setting you will need the IP of your machine, as what will be done is redirect all the traffic that get at door 80 of your router to your machine.

To get your IP, open Command Prompt and type, ipconfig. Your ip should look something like 192.168.x. x, 10.x.x.x or 172.16.x. x.

Access the router and look for the port forwarding configuration or in English, port forward. You must inform in this configuration the IP address of your machine and also the input and output port. Both the input and output port will be port 80 and the IP address of your machine.

With everything configured correctly, you must configure xampp to respond at the address of the site you registered in No-ip.

I hope it is useful and can perform its configuration.

  • 2

    It’s just that most Isps block Gate 80, precisely to prevent people from doing that sort of thing on home connections, and if you read the contract of major providers, will see that creating a web server using homemade connections violates the contract and is liable to cancel the plan.

  • Actually my intention is not to leave hosted on my machine, I intend to pay for a dedicated server, but before that, I need an environment to perform tests.

  • Bruno, I did what you suggested, but when I try to access the host that NO-IP provided, the following error occurs: Unable to access this site "..." took a long time to respond.

  • As our friend above mentioned, some ISP blocks port 80, try changing to 81 and see if you can connect. If you can, it’s because they blocked the 80 door, if not, maybe some step is wrong. Another point to validate is to disable or release the corresponding port on your firewall (from your machine).

  • I put the xampp on port 888, disabled firewall and Antivirus. I can access the xampp through "localhost:888" it shows the Dashboard screen. When I place the host or external ip followed by :888 error occurs "it took too long to respond."

  • You also put on the router the 888 port Forwarding for your machine?

  • Yes, I fixed my IP on the machine. And on the router, I set the port 888 to my fixed IP.

  • @Yagolima try the step by step answer I gave you https://answall.com/a/50934/3635

Show 3 more comments

Browser other questions tagged

You are not signed in. Login or sign up in order to post.