For a library for data compression in C#, the first results are icsharpcode/sharpziplib (SharpZipLib is a mature, stream-based C library that provides comprehensive support for multiple archive formats and compression algorithms, making it a standard tool for file management within the ), adamhathcock/sharpcompress (SharpCompress is a comprehensive, managed C library that provides stream-based support for a wide variety of compression and archive formats across the ) and miloszkrajewski/k4os.compression.lz4 (This library provides a high-performance, stream-compatible implementation of the LZ4 algorithm for ). ziparchive/ziparchive and gobwas/ws round out the shortlist. Compare the match explanations and check the project documentation against your requirements.
We curate open-source GitHub repositories matching “best c sharp compression libraries”. Results are ranked by relevance to your query — pick filters below to narrow, or refine with AI.
SharpZipLib is a .NET compression library and file archiver used to create, extract, and manage Zip, GZip, Tar, and BZip2 archives. It provides a framework for compressing and decompressing data streams and files within the .NET ecosystem. The library distinguishes itself through support for archives that exceed the standard four gigabyte size limit. It also includes capabilities for decrypting password-protected files using industry-standard encryption and managing Tar archives with long filename support. The project covers a broad range of archive management operations, including integrity
SharpZipLib is a mature, stream-based C# library that provides comprehensive support for multiple archive formats and compression algorithms, making it a standard tool for file management within the .NET ecosystem.
SharpCompress is a fully managed C# library to deal with many compression types and formats.
SharpCompress is a comprehensive, managed C# library that provides stream-based support for a wide variety of compression and archive formats across the .NET ecosystem.
LZ4/LH4HC compression for .NET Standard 1.6/2.0 (formerly known as lz4net)
This library provides a high-performance, stream-compatible implementation of the LZ4 algorithm for .NET, making it a specialized tool for data compression within the requested ecosystem.
ZipArchive is a Swift library and file utility designed for compressing and extracting files into zip archives on iOS, macOS, and tvOS. It serves as a programmatic wrapper for managing file system operations and archive creation on Apple platforms. The library supports the creation of password-protected archives using symmetric-key encryption to secure data during storage or transfer. It allows for the control of compression levels and supports the handling of large file sizes. The toolset covers core archive capabilities including the creation of compressed files from data buffers and the e
This is a Swift library designed specifically for Apple platforms, making it incompatible with the .NET ecosystem and C# development environments requested.
This Go library provides low-level components for implementing high-performance WebSocket connections. It focuses on minimal memory allocations and efficient data throughput via a dedicated frame processor, an HTTP connection upgrader, and a compression layer. The project distinguishes itself through the use of zero-allocation buffer reuse to reduce garbage collection pressure. It operates directly on raw network bytes for frame parsing and manages the lifecycle of connections through state-based tracking. The library covers core network protocol capabilities including the transformation of
This is a Go-based WebSocket networking library rather than a C# compression library, and while it includes a compression layer for network frames, it is not a general-purpose data compression tool for the .NET ecosystem.
NanaZip is a file archiver designed for the Windows operating system that provides native tools for compressing and extracting data across a wide range of archive formats. It functions as a desktop utility that manages compressed files and folders while adhering to current platform design standards and accessibility requirements. The application distinguishes itself through a focus on system-level security and native integration. It employs manifest-driven policies and strict memory management during decompression to protect against unauthorized code execution and potential vulnerabilities fo
NanaZip is a standalone desktop file archiver application for Windows rather than a C# library for developers to integrate compression and decompression capabilities into their own .NET projects.
zlib is a lossless data compression library that implements the deflate compression algorithm, combining LZ77 sliding window and Huffman coding. It provides the core compression and decompression engines, along with support for gzip, zlib, and raw deflate stream formats, enabling data to be compressed and restored without any loss of information. The library offers a range of capabilities for handling compressed data, including single-call memory and file operations, as well as incremental stream-based processing for working with data larger than available memory. It includes mechanisms for a
This is a foundational C-based compression library that provides the core algorithms, but it is not a native C# or .NET library and would require P/Invoke or a wrapper to be used within the .NET ecosystem.
This project provides a lossless compression algorithm and a byte-oriented compression library designed for high-speed data reduction and maximum decompression speed. It functions as a stream-oriented compression engine, a software library for encoding and decoding data blocks, and a command-line tool for managing interoperable compressed frames. The system distinguishes itself through the use of predefined pattern dictionaries to improve compression ratios for small data sets and small packets. It supports multiple processing modes, including high-speed block compression for minimal latency
This is a high-performance C-based compression library that serves as a foundational building block, but it is not a native C# or .NET library as requested.
Brotli is a lossless data compression library and engine that uses dictionary coding and frequency analysis to reduce file sizes. It provides tools for shrinking data streams and files while ensuring every bit of original information is preserved for perfect restoration. The project focuses on optimizing web content and network bandwidth by reducing the size of HTML, CSS, and JavaScript files. It is designed for integration into web servers and browsers to improve the efficiency of data transmission. The library includes capabilities for both compressing and decompressing data streams. It al
This is a C/C++ implementation of the Brotli algorithm rather than a native C# library, meaning it would require P/Invoke or a wrapper to be used within the .NET ecosystem.
Snappy is a high-performance lossless compression library implemented in C++. It provides data reduction methods that perfectly restore original information, focusing on system-level efficiency and processing velocity across different platforms. The library prioritizes high-speed data compression and decompression over achieving the maximum possible compression ratio. It is designed for real-time stream compression to reduce bandwidth usage without introducing significant processing latency. The implementation covers high-velocity data shrinking and rapid restoration. It includes resilient d
This is a high-performance C++ compression library, but it is not a native C# or .NET library and would require P/Invoke or a wrapper to be used within the .NET ecosystem.
MessagePack-CSharp is a high-performance binary serializer for .NET that converts C# objects to and from the compact MessagePack format. It uses compile-time source generation to produce AOT-safe formatters and resolvers, eliminating runtime reflection and enabling ahead-of-time compilation scenarios. The serializer encodes object fields as integer indices instead of string keys, producing compact binary output with deterministic field ordering, and provides stack-allocated reader and writer structs for direct encoding and decoding of MessagePack primitives without heap allocations. The libra
This is a high-performance binary serialization library that includes LZ4 compression as a transport feature, but it is not a general-purpose data compression library for arbitrary files or streams.
PeaZip is a cross-platform archive manager and file compression utility. It functions as a tool for compressing, extracting, and managing files across various formats, including 7Z, ZIP, RAR, and TAR. The project includes a specialized archive format converter for adjusting compatibility and compression levels, and a file integrity verifier for calculating checksums and hashes. It provides security tools for protecting data via authenticated encryption and passwords, as well as secure file deletion to permanently erase data from disk space. The application covers a broad range of capabilitie
PeaZip is a standalone GUI application for file management and archiving rather than a library or SDK that you can integrate into your own .NET projects for programmatic compression.
| Repository | Stars | Language | License | Last push |
|---|---|---|---|---|
| icsharpcode/sharpziplib | 3.9K | C# | MIT | |
| adamhathcock/sharpcompress | 2.6K | C# | MIT | |
| 805 |
| C# |
| MIT |
| ziparchive/ziparchive | 5.6K | C | MIT |
| gobwas/ws | 6.5K | Go | MIT |
| m2team/nanazip | 13.2K | C++ | other |
| madler/zlib | 6.7K | C | other |
| lz4/lz4 | 11.9K | C | NOASSERTION |
| google/brotli | 14.8K | TypeScript | MIT |
| google/snappy | 6.6K | C++ | NOASSERTION |