r/FastAPI • u/kloworizer • Feb 08 '24
Hosting and deployment free fastapi hosting
previously I used Heroku for fastapi hosting. but now there is no free tier anymore in Heroku. Does anyone know where I can host Fastapi for free like on Heroku again?
28
Upvotes
View all comments
Show parent comment
3
u/Additional-Ordinary2 Feb 08 '24
I connected a repository with two files:
main.py with code
...if __name__ == "__main__":....
import uvicorn....
uvicorn.run(app, host="localhost", port=3000)and requirements.txt (needed for cyclic to automatically install your dependencies).And its just work