Deploy a FastAPI App

FastAPI is a modern, fast (high-performance), web framework for building APIs with Python 3.7+ based on standard Python type hints.

One-Click Deploy

Deploy to Render

Manual Deploy

  1. You may use this repository directly or create your own repository from this template if you’d like to customize the code.

  2. Create a new Web Service on Render.

  3. Specify the URL to your new repository or this repository.

  4. Render will automatically detect that you are deploying a Python service and use pip to download the dependencies.

  5. Specify the following as the Start Command.

    uvicorn main:app --host 0.0.0.0 --port $PORT
  6. Click Create Web Service.

That’s it! Your web service will be live on your Render URL as soon as the build finishes.

See Specifying a Python Version if you need to customize the version of Node.js used for your app.