Skip to main content

Lightweight performance profiler for FastAPI applications

Project description

FastAPI Profiler Lite

FastAPI Profiler Lite Logo

PyPI version License GitHub stars CI Status Release Status

A lightweight, zero-configuration performance profiler for FastAPI applications. Monitor your API performance in real-time without external dependencies.

Dashboard Demo

Why FastAPI Profiler?

Monitoring API performance shouldn't require complex setups or external services. FastAPI Profiler gives you instant visibility into your application's performance with just one line of code.

  • Instant insights - See which endpoints are slow without complex instrumentation
  • Zero configuration - Works out of the box with sensible defaults
  • Rust-powered statistics - High-performance stats calculation using Rust
  • Developer-friendly - Designed for both development and lightweight production use

Installation

pip install fastapi-profiler-lite

For more installation options, see the Installation Guide.

Quick Start

from fastapi import FastAPI
from fastapi_profiler import Profiler

app = FastAPI()

# Add the profiler with just one line
Profiler(app)

@app.get("/")
async def read_root():
    return {"Hello": "World"}

That's it! Visit /profiler to see the performance dashboard.

Features

  • One-line integration - Add to any FastAPI app with minimal code
  • Real-time dashboard - Live updates with automatic refresh
  • Response time tracking - Measure execution time of each request
  • Endpoint analysis - Identify your slowest and most used endpoints
  • Request filtering - Search and sort through captured requests
  • Visual metrics - Charts for response times and request distribution
  • Minimal overhead - Designed to have low performance impact

Technical Details

  • Rust Core: Statistics calculations are powered by a Rust extension for improved performance. Benchmarks comparing to NumPy will be published soon. Pre-built wheels are provided for all major platforms, but if you encounter any issues, please open a GitHub issue.

  • UI Framework: The dashboard uses Tabler.io, a premium and open-source admin dashboard template, providing a clean and modern interface.

Documentation

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fastapi_profiler_lite-0.2.5.tar.gz (29.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fastapi_profiler_lite-0.2.5-py3-none-any.whl (32.2 kB view details)

Uploaded Python 3

File details

Details for the file fastapi_profiler_lite-0.2.5.tar.gz.

File metadata

  • Download URL: fastapi_profiler_lite-0.2.5.tar.gz
  • Upload date:
  • Size: 29.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.10.16 Linux/6.8.0-1021-azure

File hashes

Hashes for fastapi_profiler_lite-0.2.5.tar.gz
Algorithm Hash digest
SHA256 de06454b22bdb12e10ecaa2a461b96d8ee123dade7d733cd003c78fcd8be193c
MD5 152a88450bf3e49449e9e06e29a929ad
BLAKE2b-256 aa16e2fc8e26b4fac090cf26829ea977999f7d5c80bf60b695a97429309465d5

See more details on using hashes here.

File details

Details for the file fastapi_profiler_lite-0.2.5-py3-none-any.whl.

File metadata

File hashes

Hashes for fastapi_profiler_lite-0.2.5-py3-none-any.whl
Algorithm Hash digest
SHA256 314adb2f093e508a46f1c26915fdb4e62fb21499539eb587017a3f4b475c66e4
MD5 96528e1770c6a172125a4bb635017a3c
BLAKE2b-256 04c18e27028592dfc878b0e96974a4900ee9a53076e7ef920ce8ae38438307db

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page