GZIP compressor files to .gz

Squeeze files into .gz files in your browser, with nothing uploaded and no sign-up: each file becomes its own .gz, as the gzip command makes.

  • Files never uploaded
  • Big files welcome
  • One .gz for each file
  • Free, no sign-up

    or drop them here

      Getting ready…

      Quick facts from our tests

      Check it yourself: once the page has loaded, turn off Wi-Fi and mobile data, and GZIP Compressor still works. Your browser's network panel (F12 on a computer) lists every request the page makes: you'll see Google's ad requests, and none of them carries your file. Our code never gives your files to the ad code. How we prove it

      How to compress a file with GZIP

      1. Choose files

        Any kind, any size.

      2. Compress them

        Each squeezed with gzip.

      3. Download the .gz files

        Before and after sizes shown.

      When this tool isn't the right fit

      • Several files must travel as one. A .gz holds one file. Put them together with Create TAR.GZ or Create ZIP File.
      • Photos, videos or PDFs must get smaller. They are packed already, so gzip hardly changes them. For a PDF, use Compress PDF.
      • The file's own name must travel inside it. The browser's gzip doesn't store it: keep the .gz's name, or put the file in a ZIP.

      Why use PDFGuild's GZIP compressor

      More free tools

      Private like this one: nothing you type or add leaves your device.

      GZIP Compressor: the complete guide

      What gzip does, which files shrink, .gz and .tar.gz, logs and database dumps, programs that read .gz, web servers, and opening .gz files.

      In this guide
      1. What it does
      2. How it works
      3. Real results
      4. Step by step
      5. Which files shrink
      6. .gz, .zip or .tar.gz
      7. Who asks for .gz
      8. Logs, CSVs and dumps
      9. Programs that read .gz
      10. For websites
      11. Opening a .gz
      12. Worked examples
      13. Names
      14. Big files
      15. Checking a .gz
      16. On a phone
      17. How long it takes
      18. Privacy
      19. Problems and fixes
      20. Limits
      21. Other ways
      22. Terms explained

      What GZIP Compressor does, and when you need it

      GZIP Compressor squeezes each file you add into a .gz file, in your browser: report.csv becomes report.csv.gz, the same kind of file the gzip command makes on Linux and Macs. Nothing is uploaded, there is no sign-up, and we set no size limit. Your files are never changed; each .gz is a new file to download, and its row shows how much smaller it is.

      People use it when:

      • A log or a data export is too big to send. Text and CSV often shrink to a small part of their size.
      • A server, an API or a data portal asks for .gz. Many accept squeezed uploads, and some want them.
      • A database dump needs storing. SQL text squeezes well, and .sql.gz is how most hosting tools keep backups.
      • A website wants files squeezed ahead of time, as .js.gz or .css.gz, for its server to send to browsers.

      gzip squeezes one file into one .gz. To put several files together, use Create TAR.GZ or Create ZIP File.

      How it works

      The page reads each file as a stream and passes it through the gzip compressor built into your browser, the same deflate method ZIPs use, wrapped in gzip's small header and its check number, a CRC-32 of the whole file, which every unzip tool checks. The result is kept by the browser, on your disk when it is big, until you download it. Several files are squeezed one after another, each into its own .gz.

      Nothing is lost: gunzip, 7-Zip or any gzip tool gives back the file exactly, byte for byte.

      Why some files shrink so much: deflate looks back over the last 32 KB it has read, and when a run of bytes repeats, it writes a short pointer to the earlier copy instead of the bytes. A log line that repeats the same words with a new time and number is mostly pointers. Then the letters and pointers used most get the shortest codes. A photo, a video or a ZIP has no repeats left to find, so it stays about the same size.

      Real results from our tests

      We squeezed these test files with this page in Chromium 148, the open-source browser Google Chrome is built on, on a Windows 11 laptop with an Intel Core i7-1185G7 processor and 32 GB of memory, on 1 November 2026. Our scripts made the files to look like everyday ones; none is anyone's real file. Python's gzip module, which shares no code with the page, then unsqueezed each .gz and compared it with the original, byte for byte.

      FileBefore.gzTimeWhat happened
      A day's server log500 MB69.1 MB10.2 s86% smaller
      A shop's database backup (SQL)250 MB41.6 MB7.9 s83% smaller
      A month's sales CSV1.09 MB194 KB1.0 s83% smaller
      A phone photo (JPG)1,001 KB1,001 KB1.0 sAbout the same size: packed already
      A video-sized file600 MB600 MB18.8 sAbout the same size: packed already

      Python's gzip module unsqueezed every .gz back to the very same bytes as the original. Text, the log, the SQL and the CSV, squeezed to about a sixth of its size; the photo and the video, packed already, came out about the same, and the page said so.

      Step by step

      1. Choose the files, or drop them on the page. Any kind and any size. To try the page first, press Try with a sample file: it adds a small price list made in your browser.
      2. Press Compress to .gz. A bar shows how much has been read; the cross stops it.
      3. Download each .gz from its row. Each row shows the size before and after, and how much smaller it is, or that it is about the same size.

      Several files make several .gz files, one each, in the order you added them. Each row has its own Download, so you keep only the ones you need.

      The GZIP Compressor after squeezing the sample CSV: 2.7 KB down to a 641-byte .gz file, 76% smaller, with a Download button
      Our sample file, gzipped in the browser.

      Which files shrink

      FileAs .gz
      Logs, CSV, SQL dumps, JSON, XMLOften a tenth of the size or less: lines repeat a lot
      HTML, CSS, JavaScript, plain textUsually a quarter to a third
      PDF, Word, ExcelA little, or hardly at all: they are packed inside already
      Photos, videos, music, ZIPsAbout the same, sometimes a few bytes bigger

      The table is a rule of thumb; Real results has our measured numbers. For a PDF that must get smaller, Compress PDF shrinks its pictures instead.

      Squeezing twice gains nothing. A .gz, a ZIP or a .tar.gz is squeezed already, so putting it through gzip again, or zipping a .gz, leaves it about the same size. Squeeze the plain file, once.

      .gz, .zip or .tar.gz

      • .gz squeezes one file. It is what servers, logs, database backups and data portals use.
      • .zip holds many files and folders, each squeezed on its own, and opens everywhere. Use it for people on Windows, Macs and phones.
      • .tar.gz holds many files and folders squeezed together. Use it for Linux, servers and code.

      All three use the same deflate squeezing, so the same file shrinks about the same in each.

      Who asks for .gz files

      • Search engines. Google and Bing take a sitemap squeezed, as sitemap.xml.gz. Their 50 MB limit is for the sitemap unsqueezed, so gzip helps with the upload, not with that limit.
      • Data portals and research. Big CSV and JSON downloads are often .gz, and labs send DNA sequencing reads as .fastq.gz. Many places that hand out .gz files take them back the same way.
      • Servers and hosting. Old logs are kept as access.log.2.gz and so on, and hosting control panels make and take database backups as .sql.gz.
      • Support teams. Asked for a log, send a .gz: it is smaller, and the person on the other side has a tool that opens it.

      Logs, CSV exports and database dumps

      • Logs are the best case: lines that differ only by a time and a number squeeze to a small part of their size, which makes a week's log easy to email or attach to a support ticket.
      • CSV exports from accounting, sales or bank software repeat column values and dates, and shrink a lot. Many data portals and analysis tools read .csv.gz directly.
      • SQL dumps from MySQL or PostgreSQL are text, and .sql.gz is the usual way to keep them; restore tools read them after gunzip.

      Remove passwords, personal data or anything the other side shouldn't see before you send a log or a dump: squeezing hides nothing.

      Programs that read a .gz as it is

      Many programs read a .gz without unpacking it first, so the squeezed file can stay squeezed on your disk:

      • Python: pandas reads pd.read_csv("sales.csv.gz") directly, and the gzip module opens any .gz like a plain file.
      • R: read.csv("sales.csv.gz") works as it is.
      • Linux: zcat prints a .gz, zless pages through it and zgrep searches it, all without unpacking.
      • Databases: phpMyAdmin's Import page takes a .sql.gz, and gunzip -c backup.sql.gz | mysql -u you -p shop restores one in a single step.

      Excel and Google Sheets can't open a .csv.gz. Unpack it first with Extract TAR.GZ, then open the CSV.

      For websites: files squeezed ahead of time

      Web servers squeeze pages as they send them, and many can send a file that is already squeezed instead: style.css.gz beside style.css, for example. Squeezing them once, ahead of time, saves the server that work on every visit. Make the .gz files here, upload them next to the originals, and set your server to use them:

      • nginx: gzip_static on; sends file.gz whenever it is there.
      • Caddy: file_server { precompressed gzip } does the same.

      Keep each original next to its .gz, for the rare browser or tool that doesn't take gzip. The browser receiving a .gz unsqueezes it itself, so visitors never see it. Many hosts and CDNs squeeze files on their own: check your host's help before you upload .gz copies.

      Opening a .gz

      A .gz holds one file, so opening it gives that file back, named after the .gz with the .gz taken off.

      • Here, on any device: Extract TAR.GZ opens a .gz and gives back the file, on a phone too.
      • Windows: 7-Zip, which is free: right-click the .gz, choose 7-Zip, then Extract Here.
      • Mac: double-click it; the file appears next to the .gz.
      • Linux: gunzip report.csv.gz gives back report.csv and removes the .gz; gunzip -k keeps it.

      A worked example: a log for a support ticket

      Support asked for a day's server log, 500 MB, far too big for an email or most ticket forms. GZIP File squeezed it to 69.1 MB, 86% smaller, in 10.2 seconds, and Python's gzip module unsqueezed it back to the very same 524,288,000 bytes. Attach the .gz; anyone on Linux, Mac or Windows can open it, and log tools often read .gz files without unsqueezing them first.

      Names

      Each .gz is named after its file with .gz added: access.log becomes access.log.gz. The name isn't stored inside the .gz itself, so a tool that unsqueezes it names the file by dropping the .gz: rename the .gz and the file inside takes the new name. Type a name in the box by each Download if you want another.

      Keep the file's own ending before the .gz, as in sales.csv.gz: it tells people and programs what is inside. A .gz called just sales.gz unpacks to a file with no ending, which a computer doesn't know how to open.

      Big files

      We set no limit. A file is read as a stream, so it is never held whole in the page's memory, and the browser keeps the .gz on your disk while it is made: leave room for it. Time grows with the file's size. On a phone, files of a few GB can be more than a phone browser manages; a computer is better for those.

      Checking a .gz

      Every .gz ends with the CRC-32 and the size of the file it holds; any gzip tool checks both when it unsqueezes, and refuses a .gz damaged on the way. Three ways to test one:

      • Here: open it with Extract TAR.GZ. A good .gz shows its file and size; a damaged one gets "This file is damaged: part of it is missing or changed."
      • Linux and Mac: gzip -t file.gz tests it without unpacking, and says nothing when it is fine.
      • Windows: in 7-Zip, right-click it and choose Test archive.

      A .gz keeps its file's size in 4 bytes, so for a file over 4 GB, gzip -l lists a wrong size. The file still comes back whole, and the CRC still checks it.

      On a phone

      The page works the same in a phone's browser: choose the file from Files or Downloads, press Compress to .gz, and download it; the .gz goes where the phone keeps downloads. Phones' own file apps often can't open a .gz, so to check one, open it with Extract TAR.GZ. For files of a few GB, a computer is quicker and has more room.

      How long does it take?

      GZIP reads every byte once, so the time grows with the file's size. On our test laptop, text squeezed at roughly 30 to 50 MB a second: a 500 MB server log took 10.2 seconds and a 250 MB SQL backup 7.9 seconds. A month's sales CSV of about 1 MB took about a second, most of it the page getting the file ready rather than squeezing it.

      Files that are packed already take just as long to read but don't shrink: the 600 MB video-sized file took 18.8 seconds and came out about the same size, and a phone photo the same. If a file won't get smaller, the page says so, and you can keep the original. A phone is slower than a laptop, so a big file there takes longer; keep the page open and the screen on until the row says it is done.

      To be sure a .gz is complete before you delete the original, unsqueeze it again, for example with gunzip on Linux or Mac, and compare the two files' SHA-256 hashes with our Hash Generator: the same hash means the same file. On Linux and Mac, sha256sum or shasum does the same in a terminal, and gzip -t tests a .gz without writing anything out. Each time above is from a single run on a laptop doing other work too, so treat it as a guide rather than a promise.

      Private: your files stay on your device

      Each file is squeezed inside your browser; nothing is uploaded, and once loaded the page works with the internet switched off. Google's ad code runs on the page too, but our code never gives it your files or their names. How we prove it shows how anyone can check.

      The GZIP Compressor after squeezing the sample CSV: 2.7 KB down to a 641-byte .gz file, 76% smaller, with a Download button, at a phone's size with the internet switched off by our test, between our test's bands that read "Internet switched off" and "Nothing uploaded: 0 requests sent data"
      Proof from our testOn 9 November 2026, our test opened GZIP Compressor at a phone's size, switched the internet off and ran it on its built-in sample. It finished with no connection, and none of the page's 17 requests sent any data.How we test, and how to check it yourself

      Problems and fixes

      The .gz is hardly smaller
      The file was packed already: a photo, a video, a PDF or a ZIP. That is normal.
      "This browser can't squeeze files."
      An old browser without a built-in compressor. Update it, or use another browser.
      "This device ran out of room for the result."
      Free some disk space, or squeeze fewer files at once.
      The other side can't open it
      They need a tool that reads .gz: 7-Zip on Windows, or Extract TAR.GZ in a browser.
      The .gz is a few bytes bigger than the file
      gzip adds a small header and its check number, and a packed file can't shrink to make up for it. Send that file as it is.
      Excel won't open the .csv.gz
      Excel can't read .gz. Unpack it with Extract TAR.GZ first, then open the CSV.
      The file inside has another name
      It is named after the .gz. Rename the .gz before unpacking it, and the file takes that name.

      Limits

      • One file per .gz; for many files together, use TAR.GZ or ZIP.
      • One squeezing level, the browser's own; gzip -9 or other methods, such as zstd or brotli, can be a little smaller.
      • The original name isn't stored inside the .gz.
      • No password: gzip can't lock a file. Anyone with the .gz can open it.

      Other ways

      • Linux and Mac: gzip -k file keeps the original and makes file.gz; gzip -9 -k file squeezes a little harder, more slowly.
      • Many cores at once: pigz, on Linux and Macs, uses every core of the processor and makes .gz files any gzip tool opens.
      • Python, anywhere: python -m gzip file makes file.gz.
      • Windows: 7-Zip, with gzip as the archive kind.

      This page needs no install and works the same on a phone, a Chromebook or a locked-down office computer.

      Terms explained

      gzip, .gz
      A way of squeezing one file with deflate, losing nothing; .gz is its file ending.
      gunzip
      Unsqueezing a .gz back into the file.
      Deflate
      The squeezing method gzip and ZIP share.
      CRC-32
      The check number a .gz keeps for its file.
      Compression ratio
      How much smaller the .gz is than the file.
      .tgz
      A short name for .tar.gz: several files in a TAR, squeezed with gzip.
      Precompressed file
      A .gz made ahead of time, for a web server to send instead of squeezing the file on every visit.

      Frequently asked questions

      Is the GZIP Compressor free?

      Yes, with no sign-up and no limit set on size. Ads from Google help pay for the site, kept apart from the tool.

      Are my files uploaded?

      No. Each file is squeezed inside your browser. How we prove it shows how to check.

      What does gzip do?

      It squeezes one file with deflate, losing nothing, into a .gz that any gzip tool gives back exactly.

      Which files shrink most?

      Logs, CSV, SQL dumps, JSON and other text. Photos, videos and ZIPs hardly change.

      Can I squeeze several files into one .gz?

      No: gzip holds one file. For several, use Create TAR.GZ or Create ZIP File.

      How do I open a .gz?

      With Extract TAR.GZ, 7-Zip on Windows, a double-click on a Mac, or gunzip on Linux.

      Is anything lost?

      No: gzip is lossless, and the file comes back byte for byte.

      Is there a size limit?

      We set none; the file is read as a stream. Your device's free space is the limit.

      Why is the original name not inside the .gz?

      The browser's gzip doesn't write it. Tools name the file by dropping .gz, so keep the .gz's name or rename it.

      Can I use .gz files on my website?

      Yes: many servers can send style.css.gz in place of style.css, squeezed ahead of time.

      Is gzip the same as ZIP?

      They squeeze the same way, but a ZIP holds many files and a .gz one.

      Can I choose a stronger level?

      No: the browser's own gzip has one setting. gzip -9 on Linux can be a little smaller, more slowly.

      Does it work on a phone?

      Yes, for files of a reasonable size; each .gz goes to your Downloads.

      Can I squeeze a database dump?

      Yes, a .sql file shrinks a lot, and .sql.gz is the usual way to keep one.

      How do I check a .gz is whole?

      gzip -t file.gz on Linux or a Mac, or open it with Extract TAR.GZ, which calls a damaged one damaged.

      By the PDFGuild team · Updated · How we test