Making my web page publicly available

  • Python
  • Thread starter olgerm
  • Start date
  • Tags
    Python Web
In summary, making your web page publicly available involves making it accessible to anyone on the internet. This can be done by purchasing a domain name, selecting a hosting service, and uploading your website files. You may also need to optimize your website for search engines and promote it through various marketing techniques to attract visitors. Additionally, it is important to regularly update and maintain your website to ensure its accessibility and functionality for all users. By making your web page publicly available, you can reach a wider audience and potentially increase traffic and engagement on your site.
  • #1
olgerm
Gold Member
531
34
I want to make a web page. I made it work in local network using python and Flask module. It also saves and uses data in responses, that it has got by GET and POST requests. What should I do to make it publicly available so that I had to change the original script with flask as little as possible? I want people to be able to connect it by my ip address or I could buy a domain. I am a beginner in such things and I just want to make my web page available. Could anybody teach me how to do it?
 
Technology news on Phys.org
  • #2
olgerm said:
or I could buy a domain
That's the way I would do it... :smile:
 
  • #3
You won't be able to provide a useful service based on the usual form of home or small business internet access.
For one thing you need a static IP, that isn't the deal with most domestic providers, your IP can change, it's up to them.
Even with a static IP, domestic user band width could barely support more than 3 or 4 simultaneous users.
Yes, buy a domain, there are companies which provide that and the necessary server resources you will need at reasonable prices.
I won't recommend a particular one, but there are some that which let you experiment for free until you have a serious site going.
 
  • Like
Likes berkeman
  • #4
I think in the US, most or all Internet service providers forbid residential-service customers from operating publicly accessible servers. They may even use a firewall to block outbound connections from such servers. In other countries the situation may be different.
 
  • #5
rootone said:
could barely support more than 3 or 4 simultaneous users.
It is very small page (few kilobytes). I do not expect many users.

I want firstly make it available on my ip address before buying a domain. What code should I run to make my page available on my ip address?

Later if I buy a domain - is it then related with my ip in DNS servers and all requests to that domain are directed to my ip?
 
  • #6
Yes, you have the right idea about how DNS servers work.

As jtbell pointed out though, you may find that your ISP simply doesn't provide that kind of facilty for domestic users, even though it's possible in theory.
The way it's usually done is you get another IP, separate from your home one.
That IP addresses a server which you have rented the use of.
You can develop the site on your own PC, then upload it to that server when it looks all good.
The server you use does not have to belong to your ISP, there are companies which specialise in providing server resources.
As I said there are some who provide entry level service free, at least there were a few years ago.
It is of course the server bandwidth and storage which you pay for, they don't physically install anything at your home.
The physical server gear could be located anywhere in the world,
 
Last edited:
  • #7
I'd like to get more specific tips.

rootone said:
You may find that your ISP simply doesn't provide that kind of facilty for domestic users
I don't know if my ISP does or not. Is there a easy way to find out if it does? I prefer hosting my page from my own computer if it is possible.
What kind of source code I need to run to host my site on my ip or to upload to hosting server if I choose to rent a server? Can you give simple HelloWorld-example? The code that I have currently written and works in local network is in python3 and uses flask module.
 
  • #8
I guess the customer support at your ISP will be the people to ask.
Chances are they will try to sell you a business package that works the way I described above, by you renting some server capacity from them.
All you actually need though is a static IP which they won't change at a whim.
If they offer that at all, there very likely will be a price for it that's similar to the server rental approach.

As for actually implementing a site there are different methods.
The simplest is to write HTML fixed content pages, but that's very limiting.
Once you have got to grips with that, you'll need to look at how HTML pages can be generated from a database, and extending beyond what HTML can do, using scriptng languages like javascript
 
Last edited:
  • Like
Likes olgerm
  • #9
rootone said:
how HTML pages can be generated from a database, and extending beyond what HTML can do, using scriptng languages like javascript
I have already made that with python and flask module, but It works only in local network. I do not need any script on client side.

I do not have static IP so I will use hosting service. Most important question is that how should I modify the source code before uploading it to hosting server. Can it remain in Python?
 
  • #10
You will need to be assured that the server you use does in fact run Python, which is not something you can count on.
If it does, then your program should work the same as it does for local network.
 
  • #11
There are some advantages to running your website on your home pc rather than using a shared hosting service. For one, you will not be limited to traditional server side scripting, such as PHP or ASP. You can do anything you want in the back-end. You can have complete and fast access to everything.

But the two big deterrents are the security risks and your ISPs TOS. There's not a lot you can do about the former. There are steps you can take to decrease the risks, but you still have to open up your computer to the outside world. There's no way around it. As for the latter, you can try and find an ISP that allows home servers if your current one doesn't. Or your current ISP may allow it with a higher priced account.

There's too much involved in setting up a home server for me to go into in a forum post, but there's lots of info on the web if you just do a little research. I will give you one link to get you started: https://www.boutell.com/newfaq/creating/hostmyown.html

Also, setting up a home server is not as easy as using a hosting service. But it's a good way to learn about how the Internet works. If you have lots of time and you can manage the two deterrents I mentioned and you want to learn, then it might be worth it for you to give it a try. Otherwise, I would recommend, as the others have, that you pay for a hosting service.
 
Last edited:
  • Like
Likes olgerm and rootone
  • #12
As I understood I can not run my website on my home computer, if I do not have static IP. I do not have static IP. because of that I used hosting service Pythonanywhere. The page is now available at http://olger.pythonanywhere.com .
 
  • #13
olgerm said:
As I understood I can not run my website on my home computer, if I do not have static IP.
That's what many people think, but it's not true. You can use a Dynamic DNS service such as No-IP.com. However, you will have to use a subdomain of one of their supplied domain names such as yourdomain.theirdomain.com. Here's how it works, briefly: You create an account with the DDNS service, you choose a domain name, you tell it what your current IP is, you download and install their update client. The update client notifies the DDNS service whenever your IP changes and your domain name will be updated automatically to point to your new IP. This is the same way it works for security appliances such as IP cameras. It's all perfectly legal (if your ISP allows home servers). Some modem routers already include update clients in their firmware that's compatible with certain DDNS providers.
 
  • #14
olgerm said:
I'd like to get more specific tips.

I prefer hosting my page from my own computer if it is possible.

Here's what I do with my home server:

1. Setup dynamic DNS like TM suggested above.
2. Configure a static IP on your internal web server (usually 192.168.x.x or 10.x.x.x).
3. Configure your internet router/firewall to forward port 80/TCP to your internal web server's static IP.
4. Optional for a bit of security through obscurity - Configure the firewall to listen on a random high port and redirect to the internal default port 80 - Access from outside via httx://blah.blah.blah:randomport#
The code that I have currently written and works in local network is in python3 and uses flask module.
There shouldn't be any reason to modify the code, just be careful what you expose to the web so you don't get hacked.
 
  • Like
Likes olgerm
  • #15
http://olger.pythonanywhere.com
I can see your page!
What language is that though, Finnish?
 
  • #16
rootone said:
http://olger.pythonanywhere.com
I can see your page!
What language is that though, Finnish?
It is in estonian, but I will add english soon.
 

Related to Making my web page publicly available

1. How do I make my web page publicly available?

To make your web page publicly available, you need to host it on a server. This can be done by purchasing a hosting plan from a web hosting company, or by using a free hosting service.

2. Do I need to know coding to make my web page publicly available?

No, you do not necessarily need to know coding to make your web page publicly available. There are many website builders and content management systems (CMS) that allow you to create and publish a website without coding knowledge.

3. Is it necessary to have a domain name to make my web page publicly available?

Yes, a domain name is essential for making your web page publicly available. It serves as the address for your website, allowing users to access it through their web browsers.

4. Can I make my web page publicly available for free?

Yes, there are free hosting services available that allow you to make your web page publicly available at no cost. However, they may have limitations in terms of storage, bandwidth, and customization options.

5. How can I ensure my web page is accessible to everyone?

To ensure your web page is accessible to everyone, make sure to follow web accessibility guidelines and standards. This includes using alt text for images, providing captions for videos, and using proper heading structure for easy navigation.

Similar threads

  • Programming and Computer Science
Replies
17
Views
1K
  • Programming and Computer Science
Replies
7
Views
550
  • Programming and Computer Science
Replies
4
Views
1K
Replies
7
Views
295
  • Programming and Computer Science
Replies
15
Views
1K
  • Programming and Computer Science
Replies
17
Views
1K
  • Programming and Computer Science
Replies
4
Views
1K
  • Programming and Computer Science
Replies
1
Views
1K
  • Programming and Computer Science
Replies
4
Views
1K
  • Programming and Computer Science
Replies
3
Views
335
Back
Top