klauspost/compress

Optimized Go Compression Packages

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 57 minutes ago
Added to GitGenius on September 12th, 2026
Created on July 21st, 2015
Open Issues & Pull Requests: 9 (+0)
GitHub issues: Enabled
Number of forks: 390
Total Stargazers: 5,633 (+0)
Total Subscribers: 64 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 1.8 hours
Mean response time: 15.5 days
90th percentile: 7.9 days
Tracked items: 40

How this project is maintained

Around half of the issues opened in the past year never receive a reply. Only 16% of issues opened in the past year have been closed. Three people close 83% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 0
New in 7 days: 1
Closed in 7 days: 1
Avg open age: N/A days
Stale 30+ days: 0
Stale 90+ days: 0

Recent activity

Opened in 7 days: 0
Closed in 7 days: 1
Comments in 7 days: 0
Events in 7 days: 0

Top labels

No label distribution available yet.

Detailed Description

compress is a Go package providing optimized implementations of multiple compression algorithms.

The package addresses the need for faster compression and decompression in Go applications by offering hand-optimized implementations across several formats. It includes pure Go implementations of zstandard and S2 compression, optimized deflate packages that serve as drop-in replacements for the standard library's gzip, zip, and zlib modules, and faster variants of snappy and LZW. The package also provides lower-level entropy encoding primitives like Huffman and FSE, Microsoft XPRESS decompression support, and HTTP middleware for efficient gzipped and zstd request handling. Performance improvements are achieved through assembly optimizations and algorithmic refinements, with build tags available to disable unsafe code or assembly when needed.

Developers should adopt this package when performance matters in compression-heavy workloads. The drop-in replacement modules for gzip, zip, zlib, snappy, and LZW allow adoption with minimal code changes while gaining speed improvements. S2 is positioned as a high-performance alternative to Snappy, and the zstandard implementation enables zstd support in pure Go without external dependencies. The gzhttp module suits applications that need efficient HTTP compression negotiation. The package maintains compatibility with the current Go version and two prior versions.

The project receives active maintenance with regular updates addressing performance enhancements, platform-specific optimizations including ARM64 assembly implementations, and bug fixes. Contributions span algorithm improvements, architecture-specific code generation, and standards compliance corrections such as RFC-compliant header parsing.