badge icon

This article was automatically translated from the original Turkish version.

Article

Original Author

Sebastián Ramírez (tiangolo)

Developer

Sebastián Ramírez and Community

Platform

Windows

Linux

macOS

Initial Release

2018-12-05

Type

Software Framework

License

MIT License

Official Website

https://fastapi.tiangolo.com/

Code Repository

https://github.com/fastapi/fastapi

FastAPI is a modern, fast, and high-performance Python web framework designed for building HTTP-based API services. It was first developed by Sebastián Ramírez on December 5, 2018. It can be run on any platform compatible with Python and FastAPI components, such as Windows, Linux, and macOS. It requires Python version 3.8 or higher.

Key Features

Speed: It offers very high performance, matching the levels of NodeJS and Go thanks to Starlette and Pydantic. This makes it stand out among other Python API frameworks.

Development Speed: FastAPI accelerates developers’ work through its simplicity.

Fewer Errors: It significantly reduces errors caused by developers.

Auto-Completion: It has extensive editor support and provides auto-complete (IntelliSense) functionality in many different IDEs.

Ease of Use: It is designed with ease of learning and usage in mind, making it ideal for those who already know Python and want to develop APIs quickly.

Conciseness: It minimizes code duplication and ensures clean, maintainable code.

Robustness: Code can be deployed to production immediately. Its interactive documentation simplifies the development process.

Standards-Based: FastAPI is based on OpenAPI【1】 (formerly known as Swagger) and JSON Schema【2】, and is fully compatible with both.

Async Support: It supports the async and await keywords for improved performance.

Built-in Security: It includes mechanisms such as OAuth2, JWT, and request validation to protect against common security issues.

Components and Requirements

FastAPI uses Pydantic【3】 for data validation and Starlette【4】 for asynchronous functionality:

  • Pydantic: A data validation library for Python. It provides type hints based on annotations and simplifies debugging through auto-complete features in IDEs.
  • Starlette【5】: A lightweight framework used to support asynchronous functionality.
  • Uvicorn【6】: A minimal, low-level web server designed for asynchronous frameworks.
  • OpenAPI: FastAPI automatically generates API documentation compliant with the OpenAPI standard, including SwaggerUI and ReDoc. This allows developers to test APIs in real time. SwaggerUI is accessible at /docs and ReDoc at /redoc.

Installation

Create and activate your Python virtual environment. Then, in the terminal where the virtual environment is active, install FastAPI using this command:

This command installs FastAPI along with its standard dependencies. If you wish to install only FastAPI, you can use this command instead:

Example

A simple example of a FastAPI application:

Development: Use this command to run the code on your machine during development (if the file to be executed is main.py):

or with Uvicorn:

Production: Use this command to run the code on your machine in production (if the file to be executed is main.py):

or with Uvicorn:

Interactive API Documentation

Documentation generated via SwaggerUI is accessible at [your-url]/docs, and documentation generated via ReDoc is accessible at [your-url]/redoc.

Bibliographies

Sebastián Ramírez (tiangolo). "FastAPI Benchmarks." FastAPI Benchmarks and Speed Official Page. Accessed August 11, 2025.https://fastapi.tiangolo.com/benchmarks/

Sebastián Ramírez (tiangolo). "FastAPI Logo." FastAPI resmi logosu. Accessed August 11, 2025.https://fastapi.tiangolo.com/img/logo-margin/logo-teal.png

Sebastián Ramírez (tiangolo). “FastAPI History, Design and Future.” FastAPI geçmişi resmi sayfası. Accessed August 11, 2025.https://fastapi.tiangolo.com/history-design-future/

Citations

Author Information

Avatar
AuthorMuhammed Nabi YıldızJuly 14, 2026 at 4:41 PM

Discussions

No Discussion Added Yet

Start discussion for "FastAPI" article

View Discussions

Contents

  • Key Features

  • Components and Requirements

  • Installation

  • Example

  • Interactive API Documentation