TL;DR: Choose FastAPI for new APIs, above all ones that wait on LLMs or other services, and Flask for server-rendered apps or a team that already runs it well. FastAPI is now the more used of the two: 38% of Python developers against Flask's 34% in the JetBrains survey, and 2.9 times Flask's PyPI downloads in August 2026.
FastAPI shipped 52 releases between January and July 2026 and is still on version 0.141.1, with no 1.0 in sight. Flask shipped one release in the same period, 3.1.3 in February.
The two frameworks now differ as much in how they change as in how they run.
- 1TechEmpower has not published a valid Flask result since Round 20 in 2021, so most "5x faster" figures online have no current source.
- 2In that last head-to-head, Flask's ORM setup cost it more throughput than FastAPI's lead over raw Flask.
- 3Flask's own docs say async views do not raise how many requests it handles at once. Each request still holds a worker.
- 4FastAPI now requires Python 3.10 and Pydantic 2. Old projects pinned to Pydantic 1 cannot upgrade past 0.125.
What Is the Difference Between FastAPI and Flask?
Flask is a synchronous WSGI micro-framework for web apps and APIs. FastAPI is an asynchronous ASGI framework built for APIs, which validates requests and writes API documentation from Python type hints.
The protocol is the difference that matters. Under WSGI, one worker handles one request from start to finish.
Under ASGI, one worker can hold thousands of open requests and switch between them while each waits on a database, another API or a model.
- Built on Werkzeug (WSGI) and Jinja templates
- First released in 2010 by Armin Ronacher
- Runs on Python 3.9+
- Validation, docs and auth come from extensions you choose
- Built on Starlette (ASGI) and Pydantic
- First released in 2018 by Sebastián Ramírez
- Runs on Python 3.10+
- Validation and OpenAPI docs are built in, generated from type hints
Everything else follows from that split. The table sets the two side by side on the points teams ask about most, with versions current as of September 2026 on PyPI.
| Flask | FastAPI | |
|---|---|---|
| Server interface | WSGI (Gunicorn, uWSGI, Waitress) | ASGI (Uvicorn, Hypercorn) |
| Async views | Supported since 2.0, one worker per request | Native; sync functions run in a thread pool |
| Request validation | Manual, or an extension such as Marshmallow | Pydantic models from type hints |
| API docs | Extension (Flasgger, flask-smorest) | OpenAPI with Swagger UI at /docs |
| HTML templates | Jinja built in | Jinja available, not the focus |
| WebSockets | Extension (Flask-SocketIO, Flask-Sock) | Built in |
| Dependency injection | None built in | Depends() |
| Version scheme | Semantic, 3.x since 2023 | 0.x, minor bumps can break |
Is FastAPI Faster Than Flask?
Yes, by about 2 times on the last benchmark that ran both on the same hardware, and by up to 4.3 times on write-heavy work. That benchmark is TechEmpower Round 20, run in January 2021.

FastAPI led on all six tests. The gap was 2.7 times on JSON serialization, 1.9 times on a single database query and 4.3 times on 20 updates per request.
On JSON, Flask stopped scaling at about 60,000 requests per second from 64 connections up, while FastAPI kept climbing to 170,487 at 512 connections.
FastAPI's own results kept rising after 2021. In Round 23 (February 2025), on new hardware with 40-gigabit networking, it served 354,899 JSON requests a second and 163,894 single queries.
There is no Flask figure from that round to set beside them.
The ORM can matter more than the framework
Round 20 ran Flask twice on the single-query test: once through Flask-SQLAlchemy, once with raw SQL. The ORM version managed 14,177 requests a second. Raw SQL on the same Flask reached 34,170.

That is a 2.4-times swing inside one framework, bigger than FastAPI's 1.9-times lead over raw Flask. A team moving a slow Flask API to FastAPI while keeping the same ORM habits will get less than the benchmark headline suggests.
Profile the queries first.
What Flask's async support changes
Flask 2.0 added async def views in 2021, and many comparison posts treat that as closing the gap. Flask's documentation says otherwise:
"Each request still ties up one worker, even for async views. [...] However, the number of requests your application can handle at one time will remain the same."
Flask documentation, Using async and await
Async inside a Flask view helps when one request fans out to several slow calls at once. It does not let Flask hold more requests open.
For that, the same page points to Quart, the Pallets project's ASGI rewrite of Flask, now at 0.23.1 and requiring Python 3.13.
That limit matters most for endpoints that call a language model, which can stay open for many seconds while a reply streams back. Under WSGI, each of those waits holds a worker, so ten slow calls can fill a ten-worker Flask app.
FastAPI holds them all on one event loop.
Is FastAPI More Popular Than Flask in 2026?
Yes, on every current measure. It passed Flask in both major developer surveys and in PyPI downloads. Flask still leads on forks, a count that builds up over years.
The JetBrains and Python Software Foundation Python Developers Survey 2024 polled more than 25,000 developers in late 2024. FastAPI use rose from 29% to 38%, which JetBrains describes as a 30% increase. Flask went from 33% to 34%.
The Stack Overflow 2025 survey, which covers all languages, shows the same crossover: FastAPI 14.8%, Flask 14.4%.

Downloads tell the same story at larger scale. In August 2026, pypistats counted 559.9 million FastAPI downloads and 192.9 million for Flask, with mirrors excluded. Flask stayed between 193 and 211 million a month.
FastAPI grew by almost a third between April and August.

Downloads count every CI run and container build, and many AI tools install FastAPI as a dependency. They measure how often the package lands on a machine, not how many teams chose it.
Flask's 55 commits are not neglect. It is a small, finished core, and most of its changes happen in Werkzeug and the extensions around it.
How Do the Two Projects Change Over Time?
Flask ships a release every few months and deprecates a version ahead. FastAPI ships most weeks and drops old dependencies within days of warning about them, as the last nine months show.
pydantic.v1 compatibility layerPin exact FastAPI versions and read the release notes before each bump, since a 0.x minor version can remove things. Flask 3.x can float within its major version; its changelog lists deprecations a full release ahead.
What Does the Same Endpoint Look Like in Each?
Here is one endpoint that accepts a new user, checks the fields and returns it. In Flask, the checks are written by hand:
from flask import Flask, request, jsonify
app = Flask(__name__)
@app.post("/users")
def create_user():
data = request.get_json(silent=True) or {}
if not isinstance(data.get("email"), str) or "@" not in data["email"]:
return jsonify(error="a valid email is required"), 422
if not isinstance(data.get("age"), int) or data["age"] < 18:
return jsonify(error="age must be a number, 18 or over"), 422
return jsonify(email=data["email"], age=data["age"]), 201
In FastAPI, a Pydantic model does the checking, and the same model becomes the documented request schema:
from fastapi import FastAPI
from pydantic import BaseModel, EmailStr, Field
app = FastAPI()
class User(BaseModel):
email: EmailStr
age: int = Field(ge=18)
@app.post("/users", status_code=201)
async def create_user(user: User) -> User:
return user
The FastAPI version returns a 422 with the failing field named, and it appears at /docs with a "Try it out" button. The Flask version is more code to maintain, and someone still has to write its API docs.
EmailStr needs the email-validator package, which pip install "fastapi[standard]" includes.
For comparisons beyond Python, see how FastAPI compares with Node.js on the same measures.
Which Should You Choose?
For a new API, FastAPI. Flask is the better call in three cases: the app renders HTML pages, the team already runs Flask with extensions it trusts, or the service is small and CPU-bound, where async buys nothing.

- Choose FastAPI for: REST and JSON APIs, model-serving endpoints, services that call LLMs or other APIs, WebSockets, and any team that wants typed contracts between frontend and backend.
- Choose Flask for: server-rendered sites with forms and sessions, admin tools, prototypes that may grow into full web apps, and codebases already built on Flask-Login, Flask-SQLAlchemy or Flask-Admin.
- Consider neither: for a content-heavy app with users, permissions and an admin panel, Django ships all three and is used by 35% of Python developers in the JetBrains survey.
FastAPI's homepage lists Microsoft, Uber, Netflix and Cisco among its users. It also claims features ship "200% to 300%" faster, a figure its own footnote calls an estimate from one internal team. Treat that as marketing, not a benchmark.
How Do You Move a Flask App to FastAPI?
Route by route, not all at once. Both frameworks can run side by side behind one server while endpoints move over.
- Mount Flask inside FastAPI. FastAPI's docs use
WSGIMiddlewarefrom thea2wsgipackage to serve the existing Flask app under a path, so both run in one Uvicorn process. - Write Pydantic models first. Turn each endpoint's request and response shape into a model. This is where most hidden bugs surface, because the old code often accepted fields it never checked.
- Move the database layer before going async. A synchronous SQLAlchemy session inside an
async defroute blocks the event loop. Either keep those routes as plaindef, which FastAPI runs in a thread pool, or switch to SQLAlchemy's async engine. - Replace extensions one by one. Flask-Login maps to FastAPI dependencies with OAuth2 or JWT; Marshmallow schemas map to Pydantic models; Flasgger is no longer needed.
- Compare responses before cutting over. Send the same requests to both versions and diff the output, status codes and error shapes included.
Step 3 is where migrations stall. A route marked async that calls a blocking driver runs slower than the Flask code it replaced, because it stops every other request on the loop while it waits.
Hiring FastAPI and Flask Developers
A FastAPI migration or a new API service needs engineers who know both frameworks and async Python.
Second Talent vets Python developers, backend engineers and API developers across Asia, using questions like those in our FastAPI interview guide. See what a Python developer costs by country, or compare the platforms that hire them.
Tell us the stack and we send a shortlist of pre-vetted engineers within 24 hours. Start hiring.
FAQ
Is Flask dead in 2026?
No. It had 192.9 million downloads in August 2026 and 34% of Python developers use it. It had one release in the first half of 2026, and a stable core is what many teams want from a web framework.
Can Flask run on an ASGI server like Uvicorn?
Only through an adapter such as asgiref's WsgiToAsgi, and it stays a WSGI app underneath, one request per worker. For a real ASGI version of Flask, use Quart.
Is FastAPI production-ready if it is still version 0.x?
Yes. The 0.x number reflects its versioning policy, not its maturity. It does mean minor releases can break code, so pin the exact version and test each upgrade.





