$npx skillfedfor your agent

starlette-cramjam

Cramjam integration for Starlette ASGI framework.

Worth itPyPI WWW/HTTPReleased Apr 2026212.8K downloads / mopermissive licensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — starlette_cramjam-0.7.0-py3-none-any.whl
v0.7.0 · released 2026-04-27 · Python >=3.11 · 2 runtime deps: cramjam, starlette

Yes. The package is actively maintained, has no known vulnerabilities, low install friction, and solves a common Starlette use case with a clean API. Install it if you need HTTP compression middleware for a Starlette application and want support for multiple algorithms beyond the standard library.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.11 or later.
  • Low friction: pure Python wheel with only two runtime dependencies (cramjam and starlette).
  • Actively maintained with a recent release and no known vulnerabilities.

License · maintenance · safety

permissive license (permissive) — MIT License permits unrestricted use, modification, and distribution with minimal obligations—suitable for both open-source and commercial projects.

last release 2026-04-27 (109 days) · last repo commit 2026-07-23 · 20 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 212,832 downloads/mo, #9,449 on PyPI

Verify before relying

pip install starlette-cramjam

from starlette.applications import Starlette
from starlette.middleware import Middleware
from starlette_cramjam.middleware import CompressionMiddleware

app = Starlette(
    middleware=[Middleware(CompressionMiddleware)]
)
Same gist for agents: .md · .json

What it is and what it does

starlette-cramjam is a Starlette ASGI middleware that automatically compresses HTTP responses using one or more compression algorithms (Brotli, GZip, Deflate, ZSTD). It inspects the client's Accept-Encoding header and applies the appropriate algorithm, handling both standard and streaming responses transparently. The middleware is built on top of cramjam, which provides Rust-backed compression bindings for performance.

You configure it by specifying which compression algorithms to support, the compression level (0–11), a minimum response size threshold to avoid compressing small payloads, and optional path or media-type exclusions. It integrates directly into Starlette's middleware stack with minimal setup and requires only Python 3.11 or later.

Use it for

  • Reduce bandwidth and improve response times for text-heavy APIs by automatically compressing JSON or HTML responses.
  • Support multiple compression standards (Brotli, GZip, Deflate, ZSTD) to accommodate diverse client preferences without manual negotiation.
  • Exclude specific routes or media types (e.g., already-compressed images) from compression to avoid overhead.
  • Tune compression level per deployment environment to balance CPU cost and bandwidth savings.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

The package is actively maintained, has no known vulnerabilities, low install friction, and solves a common Starlette use case with a clean API. Install it if you need HTTP compression middleware for a Starlette application and want support for multiple algorithms beyond the standard library.

Install

starlette-cramjam on PyPI

Before you install

Low friction: pure Python wheel with only two runtime dependencies (cramjam and starlette). Actively maintained with a recent release and no known vulnerabilities.

Requires Python 3.11 or later.

License in practice

MIT License permits unrestricted use, modification, and distribution with minimal obligations—suitable for both open-source and commercial projects.

Quickstart

pip install starlette-cramjam

from starlette.applications import Starlette
from starlette.middleware import Middleware
from starlette_cramjam.middleware import CompressionMiddleware

app = Starlette(
    middleware=[Middleware(CompressionMiddleware)]
)

Package facts

Licensepermissive license permissive
Python supportSupports the current Python release >=3.11
Install frictionLow. Pure-Python wheel
Runtime dependencies
2 packages
cramjamstarlette
MaintenanceActively maintained 109 days since the last release
Last repo commit
First released
Downloads212,832 / month, #9,449 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Intended Audience :: Information TechnologyIntended Audience :: Science/ResearchLicense :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Typing :: Typed

Evidence: starlette_cramjam-0.7.0-py3-none-any.whl

Tags

Capabilities
starlette compression middlewarebrotli gzip deflate zstd compressionasgi response compressionhttp content encoding middlewarestarlette middleware compression
Topics
asgi-middlewarecompression
PyPI keywords
ASGICompressionCramjamStarlette

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 › “starlette compression middleware”

  • starlette-cramjamMiddleware for Starlette that compresses HTTP responses using Brotli,…
  • starlette-compressMiddleware for Starlette and FastAPI that compresses HTTP responses…
  • brotli-asgiBrotliMiddleware adds Brotli compression to ASGI applications as a…

Give your agent the search over MCP, or paste the wish link into any chat.

More WWW/HTTP packages

urllib3 Worth it
PyPI · Libraries · released May 2026

urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.

MITpure Python · 3.10+
1.8Bdownloads / mo
requests Worth it
PyPI · Libraries · released May 2026

Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.

Apache-2.0pure Python · 3.10+
1.8Bdownloads / mo
h11 With conditions
PyPI · WWW/HTTP · released Apr 2025

h11 is a pure-Python HTTP/1.1 protocol implementation that handles parsing and serializing HTTP messages without any built-in I/O, letting you integrate it with any network layer you choose.

MITpure Python · 3.8+aging
894.9Mdownloads / mo
httpx Worth it
PyPI · WWW/HTTP · released Dec 2024

HTTPX is a fully featured HTTP client library for Python that provides both sync and async APIs, with support for HTTP/1.1 and HTTP/2, plus an integrated command-line client.

Install it if you are building new projects or modernizing existing ones that rely on HTTP.

BSD-3-Clausepure Python · 3.8+
797.0Mdownloads / mo
httpcore With conditions
PyPI · WWW/HTTP · released Apr 2025

A minimal low-level HTTP client library that sends HTTP requests with thread-safe and task-safe connection pooling, supporting HTTP/1.1, HTTP/2, proxies, and both sync and async interfaces.

BSD-3-Clausepure Python · 3.8+aging
783.6Mdownloads / mo
aiohttp Worth it
PyPI · WWW/HTTP · released Jul 2026

aiohttp is an async HTTP client and server framework built on asyncio, supporting both WebSockets and middleware-based routing for building concurrent web applications.

Install it if you need async HTTP client or server capabilities in asyncio-based applications.

permissive licensecompiled wheel · 3.10+
643.6Mdownloads / mo

See also brotli-asgi · cramjam · starlette · starlette-compress · Flask-Compress · starsessions · asgi-correlation-id · starlette-context · starlette-testclient · opentelemetry-util-http