GZIP decompress

Input
Output

GZIP Decompress

Decompress GZIP data (as Base64, the way APIs and logs often carry it) and see the JSON inside, or compress JSON into GZIP Base64.

Example: a CloudWatch Logs payload

AWS CloudWatch Logs hands log events to a Lambda function or a Firehose stream as GZIP compressed, Base64 encoded JSON (in a Lambda event it's the awslogs.data field). Paste that string as it is:

Input

H4sIAAAAAAAA/zWPS2vDMBCE/4oRPSbo4adyM0TJJSVg+xZMke0lFbUsI8kNIeS/V07bPX4zO7vzQBqck1do7jOgHdqXTfnxLuq6PAq0QeY2gQ2YsjhJs7zghLKAR3M9WrPMQcHy5vAodTdI3H9C/2UW/+uovQWpg4URlmFKMOP48nYqG1E3raTdGuSWzvVWzV6Z6aBGD9ah3QXN8q5h8luw1gTSvvLEd0Cr/EBqCLFxkeY5TTgjGS3SJF7zvAp1vNThM5rzmGUFec3mv2bYE1V1rqK/E9EA/agmGKJztd8yklCOnu3zBy79dX4XAQAA

Output

{
  "messageType": "DATA_MESSAGE",
  "owner": "123456789012",
  "logGroup": "/aws/lambda/checkout",
  "logStream": "2026/10/29/[$LATEST]a1b2",
  "subscriptionFilters": [
    "payment-errors"
  ],
  "logEvents": [
    {
      "id": "38577149206185432",
      "timestamp": 1793268000000,
      "message": "ERROR payment declined ORD-20419"
    }
  ]
}

How do I use the GZIP decompress?

  1. Paste Base64-encoded GZIP data.
  2. Read the decompressed JSON.
  3. Or switch direction to compress JSON.

What does the GZIP decompress do?

  • Both directions
  • Formats JSON found inside
  • Runs on your device

When to use the GZIP decompress

GZIP data turns up as Base64 wherever compressed bytes have to travel as text: CloudWatch Logs subscriptions, message queues, cached API responses and fields in log lines. If a long string starts with H4sI, it's almost certainly GZIP: those four characters are the GZIP header bytes 1f 8b 08 written as Base64.

Bracely takes standard or URL-safe Base64, with or without line breaks, unpacks it in your browser and formats the JSON inside. If what's inside isn't JSON you get the plain text. Compressing goes the other way: JSON is minified first so the result is as small as it can be, and any other text is compressed exactly as typed.

You rarely need this for a normal API call, because the browser already unpacks responses sent with Content-Encoding: gzip. You need it when the compressed bytes are stored or passed along as a value: in a log line, a queue message, a database column or a webhook field.

Frequently asked questions

Why does it say the data should start with H4sI?
Every GZIP stream begins with the bytes 1f 8b 08, which are H4sI in Base64. If your string starts differently it may be plain Base64 (try Base64 to JSON), zlib or raw deflate data without the GZIP header, or hex rather than Base64.
How do I decode the awslogs.data field from CloudWatch Logs?
Paste the value of event.awslogs.data as it is. It's GZIP compressed JSON in Base64, and you'll see the log group, the stream and every log event inside, as in the example above.
Can I open a .gz file?
Yes, in the Large file viewer: drop the .gz file there and it's unpacked as it's read, even when it holds gigabytes of JSON Lines.
Is my data uploaded?
No. Bracely runs entirely in your browser, so nothing you paste or open leaves your device.

More JSON tools

Bracely has 108 JSON tools in one page. Related ones:

Runs entirely in your browser. Nothing you paste is uploaded. Made by Saurabh Pagrut · About · Privacy policy
Last updated · Version 6.7 · Changelog
Saurabh Pagrut on GitHub · LinkedIn · X · YouTube · Instagram