1. Quickstarts
  2. FastAPI

Deploy a FastAPI App

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

Here’s how to deploy a basic FastAPI app on Render.

  1. Create your own repository using the render-examples/fastapi template on GitHub.
    • Alternatively, you can clone the repo and push your clone to GitLab or Bitbucket.
  2. Create a new Web Service on Render, and give Render permission to access your new repo.
  3. Provide the following values during service creation:
    SettingValue
    RuntimePython
    Build Commandpip install -r requirements.txt
    Start Commanduvicorn main:app --host 0.0.0.0 --port $PORT

That’s it! Your web service will be live at its onrender.com URL as soon as the deploy finishes.

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