litellm
Library to easily interface with LLM API providers
Decision gist · record as of 2026-08-14
Yes, with conditions. LiteLLM is actively maintained, permissively licensed, and widely adopted (top 100 PyPI by downloads). Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization. The 13 dependencies add medium friction; evaluate whether the abstraction layer justifies that cost for your use case. No known vulnerabilities as of the fact sheet date.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later (supports up to 3.14).
- API keys for at least one LLM provider must be set as environment variables.
- Medium install friction: 13 runtime dependencies including httpx, openai, pydantic, aiohttp, and tokenizers.
License · maintenance · safety
MIT (permissive) — MIT license permits commercial and private use with minimal restrictions—suitable for enterprise deployment as an AI Gateway or embedded in production applications.
last release 2026-08-11 (3 days) · last repo commit 2026-08-14 · 56,281 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 682,782,233 downloads/mo, #46 on PyPI
Alternatives
Verify before relying
pip install litellm
from litellm import completion
import os
os.environ["OPENAI_API_KEY"] = "your-key"
response = completion(
model="openai/gpt-4o",
messages=[{"role": "user", "content": "Hello!"}]
)- Actual latency performance at scale (description claims 8ms P95 at 1k RPS but this is not independently verified in the fact sheet)
- Completeness and stability of support for all 100+ claimed providers across different endpoint types
- Enterprise feature maturity (virtual keys, spend tracking, guardrails, load balancing, admin dashboard)
What it is and what it does
LiteLLM is a unified interface layer that abstracts away the differences between multiple LLM providers. Instead of learning separate SDKs for OpenAI, Anthropic, Gemini, Bedrock, and others, you write code once using OpenAI's API format and swap providers by changing a model string. It works as a Python library for direct integration or as a self-hosted proxy server (AI Gateway) that your team or organization can deploy centrally.
The package handles authentication, request formatting, error translation, and response normalization across providers. It includes 13 runtime dependencies (httpx, openai, pydantic, aiohttp, tokenizers, and others) to manage HTTP communication, token counting, configuration, and async operations. The proxy server adds production features like virtual keys, spend tracking, and load balancing. It also supports agent protocols (A2A), MCP tool bridging, and multiple endpoint types beyond chat completions.
Use it for
- Build an LLM application that can switch between providers without code changes, for cost optimization or fallback resilience.
- Deploy a centralized AI Gateway for your team to route all LLM requests through a single service with unified authentication and monitoring.
- Integrate multiple LLM providers (e.g., OpenAI for chat, Anthropic for reasoning, Gemini for vision) in a single codebase using consistent API calls.
- Track and control LLM spending across multiple providers and models from one dashboard.
- Connect MCP servers or A2A agents to any LLM without provider-specific glue code.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, with conditions.
LiteLLM is actively maintained, permissively licensed, and widely adopted (top 100 PyPI by downloads). Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization. The 13 dependencies add medium friction; evaluate whether the abstraction layer justifies that cost for your use case. No known vulnerabilities as of the fact sheet date.
Install
litellm on PyPI
Before you install
Medium install friction: 13 runtime dependencies including httpx, openai, pydantic, aiohttp, and tokenizers. Active maintenance with releases every few days and 56281 GitHub stars. Wheels available for Python 3.10+ across macOS, Linux, and Windows architectures.
Requires Python 3.10 or later (supports up to 3.14). API keys for at least one LLM provider must be set as environment variables.
License in practice
MIT license permits commercial and private use with minimal restrictions—suitable for enterprise deployment as an AI Gateway or embedded in production applications.
Quickstart
pip install litellm
from litellm import completion
import os
os.environ["OPENAI_API_KEY"] = "your-key"
response = completion(
model="openai/gpt-4o",
messages=[{"role": "user", "content": "Hello!"}]
)
Verify before relying
- Actual latency performance at scale (description claims 8ms P95 at 1k RPS but this is not independently verified in the fact sheet)
- Completeness and stability of support for all 100+ claimed providers across different endpoint types
- Enterprise feature maturity (virtual keys, spend tracking, guardrails, load balancing, admin dashboard)
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release <3.15,>=3.10 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | 13 packagesfastuuidhttpxopenaipython-dotenvtiktokenimportlib-metadatatokenizersclickjinja2aiohttppydanticpydantic-settingsjsonschema |
| Maintenance | Actively maintained 3 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 682,782,233 / month, #46 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
Evidence: litellm-1.96.2-cp310-abi3-macosx_10_12_x86_64.whl; litellm-1.96.2-cp310-abi3-macosx_11_0_arm64.whl; litellm-1.96.2-cp310-abi3-manylinux_2_28_aarch64.whl; litellm-1.96.2-cp310-abi3-manylinux_2_28_x86_64.whl; litellm-1.96.2-cp310-abi3-musllinux_1_2_aarch64.whl; litellm-1.96.2-cp310-abi3-musllinux_1_2_x86_64.whl; litellm-1.96.2-cp310-abi3-win_amd64.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “cross-provider llm sdk”
- litellmLiteLLM provides a unified Python interface to call 100+ LLM…
- apache-airflow-providers-common-ioProvides common I/O utilities and operators for Apache Airflow…
- kclikcli is a command-line provisioning and management tool for virtual…
Give your agent the search over MCP, or paste the wish link into any chat.
More Artificial Intelligence packages
Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.
Install it if you work with Hugging Face Hub models or datasets.
LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.
hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.
Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.
Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.
Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.
LangChain Core provides the foundational abstractions and interfaces for building LLM applications, enabling modular composition of language model chains, agents, and tools across the LangChain ecosystem.
Install it if you are building any LLM application that benefits from modular abstractions and ecosystem interoperability.
See also any-llm-sdk · g4f · litellm-enterprise · unclecode-litellm · astra-assistants · models-dev · headroom-ai · fhlmi · litellm-proxy-extras · promptlayer