Deploy a FastAPI app

This quick start guide will show you how to deploy a basic FastAPI application using seenode -- a developer-friendly platform for deploying and hosting FastAPI apps.

This guide assumes you already have a FastAPI app and a seenode account ready.

Project structure

Your project structure should look something like this:

my-fastapi-app/
├── main.py
├── requirements.txt

Example main.py

Seenode needs to know how to run your app. Here’s a minimal example of your main file (main.py):

from fastapi import FastAPI

app = FastAPI()

@app.get("/")
def read_root():
    return {"message": "Hello from FastAPI"}

Make sure your app instance is named app, and it’s importable from main.py.

requirements.txt

Include at least the following in your requirements.txt:

fastapi
uvicorn[standard]

You can add any additional dependencies your app uses.

Last updated