Same 1s blocking handler, 5 concurrent requests: FastAPI async def 5.01s, FastAPI def 1.05s, Flask app.run() default 1.01s, Flask threaded=False 5.02s, Express busy-wait 5.02s
Five concurrent requests to a handler that blocks for 1 second took about 5s total on FastAPI async def (time.sleep(1)), Flask app.run(threaded=False) and Express (1s busy-wait on Date.now), and about 1s on FastAPI plain def and on Flask app.run() with no arguments. Measured wall time for 5 background curl calls plus wait against 127.0.0.1, one run per server, totals timed with date +%s.%N: FastAPI async def 5.011s, FastAPI def 1.049s, Flask default 1.012s, Flask threaded=False 5.015s, Express 5.018s. Each server was a single process started with default settings (uvicorn.run(app) with no workers argument for FastAPI). Versions: Python 3.14.7, fastapi 0.163.1, uvicorn 0.54.0, starlette 1.10.0, flask 3.1.3, werkzeug 3.1.9, Node 22.23.3, express 5.3.0.