Last time I talked about FastRAPI, people came up to me and told me they'd wanna hear more about it, if I wasn't limited by the time. I told them I'd come to IndiaFOSS, 2026. Here I am.
Building API's using FastAPI is very FAST. But does it run FAST? what about after Python removed it's GIL? NO 😔. Tiangolo is a great dev, and I admire him. The source code of FastAPI is very lovely. The interpreted language is hitting the bottlenecks. So I decide to take it in my own hands, and tried to solve it.
This is real world, we have HIGH throughput applications where every millisecond of latency matters, and where horizontal scaling becomes prohibitively expensive.
Example scenarios:
- How would you handle millions of requests per second on a single server without rewriting your entire codebase in Go or Rust?
- How do you keep your same syntax and get 6x better performance?
Given: You have an existing FastAPI application with thousands of lines of code
When: You need 10x better throughput without changing your API contract
Then: What options do you have besides "rewrite everything in a compiled language"?
sneakpeak: FastrAPI kinda works as a compiler doing most of it's work at the startup maintaining fast startup times :)
Even though we can optimize Python code, add more workers, or scale horizontally, we eventually hit fundamental limits of the Python runtime/interpreted language. These performance critical scenarios require a different approach, one that doesn't force you to abandon Python! In this session, I will demonstrate FastrAPI, an open-source framework that delivers Rust-level performance while keeping your familiar Python syntax. I will show real benchmarks, explain the architecture, and demonstrate how to migrate existing FastAPI applications with a single line change, and most importantly, ALL THE OPTIMIZATIONS and MICRO-OPTIMIZATIONS (From cache locality to Hashing algorithms).
I would love to delve more deeper this time, also talking about more optimizations that was implemented since the last version, too.
The ability to:
- Use same FastAPI decorator syntax (@app.get, @app.post)
- Achieve 6x performance improvement over FastAPI + Gunicorn in real-world benchmark
- Maintain full Pydantic integration for request/response validation
- Handle 40,000+ requests per second with sub-millisecond average latency
- Add middleware (CORS, GZip, TrustedHost, Session) and other custom ones exactly like FastAPI
- Migrate existing applications by changing a single import statement
- Make use of other useful features for DDOS Protection
- Leverage Rust's type safety and memory efficiency without writing Rust code
- Run sync and async Python handlers on Tokio's high-performance runtime
- Build production APIs with minimal memory overhead and maximum throughput