Skip to content
Bytevive

“Compressed (zipped) folder is invalid” or Mac “Unable to expand”: what each ZIP error really means

What the Windows and macOS extractors are telling you, the error numbers decoded, Terminal commands that often work, and what to do when the ZIP is damaged.

By the Bytevive team8 min read

A MacBook showing Archive Utility’s “Unable to expand” error for a downloaded ZIP

On Windows it’s “The compressed (zipped) folder is invalid.” On a Mac, Archive Utility says it was “Unable to expand” the file and adds an error number in brackets: 1, 2, 79, sometimes 94. Neither message tells you much, and both come from the extractors built into the operating system, which are deliberately simple.

This guide is about those built-in tools: what they can’t do, what the Mac numbers mean, and the commands that often open the archive anyway. If you’re seeing “unexpected end of archive” in 7-Zip or WinRAR instead, our guide to corrupted ZIPs and cut-off downloads is the better starting point.

Step 1: is it really a ZIP?

Start with the size. If the download page said 480 MB and you have 37 KB, the problem isn’t the extractor. When a download link has expired or needs a login, many servers send back a web page instead, and your browser saves it under the name you expected.

The first bytes settle it. On Windows, in a terminal opened in the download folder:

Format-Hex -Path archive.zip | Select-Object -First 1

On a Mac, in Terminal:

cd ~/Downloads
xxd -l 16 archive.zip
First bytes (hex)As textWhat you have
50 4B 03 04PK..A ZIP starting with its first file’s header, as almost all do
50 4B 05 06PK..Just an end record: a ZIP with no files in it
3C 21 44 4F or 3C 68 74 6D<!DO or <htmA web page saved as .zip. Download it again, signed in if needed
00 00 00 00 all the way(blank)An empty or never-written file. Nothing to extract

The ZIP signatures come from the Library of Congress, which notes that the local file header signature 50 4B 03 04 is written 0x04034b50 in the specification because ZIP stores numbers little-endian. It also points out that a ZIP doesn’t strictly have to begin with a file entry, so an unusual start isn’t proof on its own. A web page or a block of zeros is.

What a built-in extractor reads first

A ZIP lists its contents at the end. A simple extractor that can't find a valid end record gives up on the whole file.

  1. PK\3\4File 1
  2. PK\3\4File 2
  3. PK\3\4File 3
  4. PK\1\2Central directory
  5. PK\5\6End record
First byteLast byte
Not to scale. The specification's signatures are 0x04034b50 for each file, 0x02014b50 for each directory entry, and 0x06054b50 for the end record.

What Windows’ built-in extractor won’t do

File Explorer’s Extract All handles everyday ZIPs and little else. Microsoft’s own help page says Windows 11 version 24H2 supports ZIP, RAR, 7z, and TAR, but that it “does not support operations on encrypted archive files,” and suggests 7-Zip or WinRAR for those. On older versions of Windows, don’t count on anything beyond plain ZIP.

Before reaching for another program, try PowerShell’s built-in Expand-Archive. It’s a separate implementation from File Explorer’s, so it sometimes opens what Explorer refuses, and when it fails it prints an error message you can search for:

Expand-Archive -Path archive.zip -DestinationPath archive-files

If both fail, the free 7-Zip is the next step, and its Test command shows which files are affected (see our 7-Zip archive error guide if 7-Zip refuses it too).

What the Mac error numbers mean

The numbers Archive Utility shows line up with the standard error codes in macOS’s own errno.h header. Apple doesn’t document Archive Utility’s errors, so treat this as the widely reported mapping rather than an official one. The descriptions are the system’s; the right-hand column is our reading of what each usually means for a ZIP.

ErrorSystem descriptionUsually means
1Operation not permittedmacOS refused an action, for example writing to the destination folder. Try another location or Terminal
2No such file or directorySomething the extractor needed wasn’t where it expected. Retry from a simple folder such as Downloads, or use Terminal
28No space left on deviceThe unpacked files don’t fit. Free up space; they can be much larger than the ZIP
79Inappropriate file type or formatNot a ZIP it can read: a mislabeled file, a cut-off download, or an unsupported feature
94Bad messageData inside didn’t decode properly, which points to damage or an unusual method

The Terminal fallbacks on a Mac

macOS ships with two command-line tools that read ZIPs independently of Archive Utility. Open Terminal and run these from the folder that holds the archive:

cd ~/Downloads

# Test every file without extracting anything
unzip -t archive.zip
echo $?

# Extract with Apple's ditto (-k means PKZip format)
ditto -x -k archive.zip archive-files

# Or extract with Info-ZIP
unzip archive.zip -d archive-files

According to the unzip manual, -t “extracts each specified file in memory and compares the CRC” with the one stored in the archive, so it tells you file by file whether the contents are intact. echo $? prints its exit code. ditto creates the destination folder if it doesn’t exist, and for a password-protected ZIP it needs the --password option to prompt you.

Unsupported method or real damage?

Each file in a ZIP records how it was compressed. PKWARE’s APPNOTE specification lists method 8 (Deflate), the near-universal default, alongside 9 (Deflate64), 12 (BZIP2), 14 (LZMA), 95 (XZ), 98 (PPMd), and 93 (Zstandard), which was added in version 6.3.7 of the document. Not every extractor supports every method, and an archive made by a specialist tool may use one your built-in extractor doesn’t know.

To see which method each file uses, run unzip -v archive.zip. The manual says the verbose listing adds “the compression method, compressed size, compression ratio, and 32-bit CRC” for each entry. If the methods are unusual and unzip -t reports no CRC errors, the archive is fine; use a tool that supports the method. If the files use ordinary Deflate and still fail their checks, the data really is damaged.

When the ZIP really is damaged

Simple extractors rely on the central directory at the end of the archive and stop if it’s wrong (you can step through how that happens in our interactive ZIP walkthrough). A repair tool doesn’t have to. Here’s how Bytevive’s ZIP Repair works:

  1. Sign in with a free account and drop the archive onto the page. It’s read in your browser, not uploaded.
  2. It reads the central directory, then scans the whole archive for local file headers anyway, so it finds files the directory lost or never listed.
  3. It decompresses each file and checks its CRC-32, then reports it as intact, damaged, or impossible to check (encrypted, or packed with an unusual method).
  4. You download a clean, rebuilt ZIP of the files that passed, which the built-in extractors open normally.

It handles ZIP files up to 1 GB, free. It doesn’t do RAR or 7z.

What no tool can fix

  • Files that were never downloaded. If the archive was cut off, everything after the cut is missing. Download it again.
  • Encrypted files without the password. Command-line tools like zip -FF can copy encrypted entries untouched, while Bytevive flags them in the report and builds the new ZIP only from verified, unencrypted files. Either way, nobody can check or open encrypted entries without the key.
  • Files that fail their CRC. Some bytes inside changed. You can tell they’re bad; you can’t make them good.
  • Something that was never a ZIP. A saved web page has no files in it to recover.

The bottom line

“The compressed (zipped) folder is invalid” and “Unable to expand” are the built-in tools saying they can’t read the file, not proof that your files are gone. Check the size and the first bytes, try Expand-Archive or unzip -t, and let the exit code tell you whether you need a different tool, the rest of the download, or a repair. For the last case, check the archive in your browser and keep every file that passes.

Frequently asked questions

What does "the compressed (zipped) folder is invalid" mean?
Windows' built-in extractor couldn't read the archive. The file may not be a ZIP at all (a web page saved with a .zip name is common), it may be incomplete, it may use a feature Windows doesn't handle such as encryption, or it may be damaged. Checking the size and the first bytes tells you which.
What is error 79 when unzipping on a Mac?
79 is the macOS system error code for "Inappropriate file type or format". Archive Utility appears to pass these codes through, so error 79 means it didn't recognize the data as an archive it could read: the file isn't really a ZIP, it's cut off, or it uses something Archive Utility doesn't support.
Why does the ZIP open on one computer but not another?
Extractors support different subsets of the ZIP format. Encryption and less common compression methods are the usual differences. A fuller tool, or the command line, often opens what a built-in extractor refuses.
Can Bytevive repair RAR or 7z files?
No, ZIP only for now, up to 1 GB. For RAR, WinRAR's Repair archive command is the standard tool. Our guide to the 'unexpected end of archive' error covers the alternatives.
Is my archive uploaded when I use Bytevive?
No. The ZIP is read and checked inside your browser tab and never leaves your device. It's free with a free account.

Sources

Every claim, error message, price, and limit cited above comes from these pages, checked on November 22, 2026. If one has changed, tell us at support@bytevive.com and we’ll update the article.

  1. Microsoft Support: Zip and unzip files (supported formats and encryption)
  2. Microsoft PowerShell docs: Expand-Archive
  3. Apple open source: xnu bsd/sys/errno.h (macOS error codes)
  4. Library of Congress: ZIP file format family
  5. PKWARE: APPNOTE.TXT, the ZIP file format specification
  6. Info-ZIP unzip manual (-t, -v and exit codes)
  7. SS64: ditto (macOS)
  8. SS64: xxd (macOS)

ZIP won't extract? Rescue what's inside.

Free account, archives up to 1 GB. Every file is checked, and nothing is uploaded.

Repair a ZIP, free

Other free tools: video, PDF, photo, Office, ZIP, and audio repair.