Skip to content
Marvin's Toolbox.

Search tools

Type to filter all tools

Data Compressor

Compress text or a file with gzip, deflate, brotli or Zstandard and see the size before and after, the compression ratio and how long it took. One click tries every method and recommends the smallest result.

Everything runs locally in your browser. Your data never leaves your device.

Input

Method

6

0 is fastest, 9 compresses hardest.

Add some text or a file first.

Next steps

Send this tool's output straight into another tool.

Decompress gzip, deflate, brotli or Zstandard data from a file or pasted Base64 and read the result as text or download it. Detects the format from the magic bytes where possible, with a manual override.

Hash text or a file with MD5, SHA-1, SHA-256, SHA-512, SHA-3, BLAKE2, BLAKE3, CRC32 and more, all computed live as you type. Compare against an expected checksum and copy any digest.

Verify a checksum online: drop a file, paste the expected checksum and see instantly whether they match. The hash type is detected from the checksum itself, covering MD5, SHA-1, SHA-256, SHA-512, BLAKE3, CRC-32 and more, and sha256sum lines or whole checksum files can be pasted as-is.

Compress text or a file with gzip, deflate, brotli or Zstandard and see the size before and after, the compression ratio and how long it took. One click tries every method and recommends the smallest result.

Inspect any file or text as a hex dump with offsets, byte values and an ASCII column. Jump to an offset, search for bytes or text, select a range to see it decoded as integers and strings, and copy or download the dump.

Encrypt any file with a password using AES-256-GCM, or decrypt a file that was encrypted here. Strong key derivation and integrity protection built in.

About the Data Compressor Tool

This tool compresses text or a file with gzip, deflate (zlib), raw deflate, Brotli or Zstandard and shows exactly what you gained: the size before and after, the percentage saved, the compression ratio and how long the codec took.

Not sure which method to pick? One click on Find best method runs all five over your data and recommends the smallest result. You can then forward the output straight to the Data Decompressor to verify the round trip.

What you can do

  • Compress text or any file with gzip, deflate, Brotli or Zstandard.
  • Compare every compression method on the same data and pick the smallest result.
  • Measure the compression ratio and speed of gzip, Brotli and zstd.
  • Download the result with the right extension (.gz, .zz, .deflate, .br or .zst).
  • Copy small results as Base64 for configs, tickets or tests.

How to use the Data Compressor

  1. 1Paste text, or switch to File and drop any file.
  2. 2Pick a method and set its level or quality, or press Find best method to try them all.
  3. 3Read the before and after sizes, the space saved, the ratio and the time taken.
  4. 4Inspect the compressed bytes in the hex view, download the file, or copy it as Base64.

Choosing a method

gzip is the safe default, every tool and server understands it. Brotli usually produces the smallest output for text and web assets but takes longer at high quality. Zstandard gets close to Brotli while compressing and decompressing much faster, which is why it is popular for build artifacts and backups. deflate (zlib) and raw deflate are the same algorithm gzip uses, just with a lighter or no container, for when a spec asks for exactly that framing.

How Find best method works

Find best method runs every codec over the same input at its strongest practical setting: level 9 for gzip and the deflate variants, quality 11 for Brotli and level 19 for Zstandard. The results are sorted by size, the smallest is highlighted and adopted as the active result, and each row reports its timing so you can trade a few percent of size against speed.

When compression makes data bigger

Already compressed data such as JPEG photos, video or ZIP archives has little redundancy left, so a second pass often grows it slightly. The tool reports that honestly as a negative saving instead of hiding it. Random or encrypted data behaves the same way.

Credits

Open source does the heavy lifting in this tool. Thank you to:

  • brotli-wasm

    Google's Brotli compression, compiled to WebAssembly.

  • zstd-wasm

    A WebAssembly build of Zstandard, the fast modern compression format.

Everything this site builds on is listed on the credits page.

Decompress gzip, deflate, brotli or Zstandard data from a file or pasted Base64 and read the result as text or download it. Detects the format from the magic bytes where possible, with a manual override.

Shrink an SVG with SVGO. Paste the markup or drop a file, toggle every optimizer plugin individually, set the numeric precision and multipass, and compare the size before and after. Copy the result or download it as a file.

Enter a resolution to get its simplified aspect ratio, or start from a ratio and one side to get the missing dimension. Knows the common ratios like 16:9, 4:3 and 21:9 and shows how close your size is to each.

Create barcodes in dozens of formats, from EAN-13, UPC-A and Code 128 to QR Code, Data Matrix and PDF417. Type the content, tune the size, colors and text options, and download the result as PNG or SVG.

Decode Base64 to text or encode text to Base64. Paste into the top box, read the result below, and flip the direction with one click. Handles Unicode correctly, reads URL-safe Base64, and shows binary payloads as a hex dump you can download.

Hash a password with bcrypt or Argon2 and verify a password against an existing hash. Tune the cost factor, memory, iterations and parallelism, see how long the hash takes, and read the parsed parts of any hash you paste.