You built a Flask app that works on your computer. Now you want other people to use it. Here is a simple, free way to put it online.
Before you start
A working Flask app (even a very small one)
A free GitHub account
A free account on a hosting service such as Render
Free plans change over time and have limits (for example, a free app may go to sleep after a period without visitors), so check the current terms on the hosting site.
Step 1: Prepare your project
Your project folder should look like this:
my-app/ app.py requirements.txt templates/ static/
Enter fullscreen mode
Exit fullscreen mode
Here is a minimal app.py :
from flask import Flask
app = Flask ( __name__ )
@app . route ( "/" ) def home ( ) : return "Hello from my Flask app!"
Enter fullscreen mode
Exit fullscreen mode
Step 2: List your dependencies
Create a file called requirements.txt that names every package your app needs.…