It's likely that filename.zip is either not actually a .zip file, or is corrupted.
Open up Terminal. You can access it by typing "Terminal" into Spotlight.
Enter the command(s) in the steps below into your command line prompt (triple click the line, copy it, and paste it into your prompt). Replace filename.zip with the actual name of the zip file.
If the name of the file contains spaces, you need to enter it differently using the escape \ character. For example, if the file is named compressed crap.zip, you'd type compressed\ crap.zip in the command line.
Step 1:
Repair disk permissions. Once done, attempt to open the .zip file again. If you wish, you can do this from the command line.
diskutil repairPermissions /
Step 2:
Use file to confirm it's actually a zip file:
file ~/Downloads/filename.zip
The output should be:
Zip archive data, at least v2.0 to extract
If you don't receive this output, post the output as a comment before proceeding.
Step 3:
After confirming it's actually a zip file, attempt to unzip it directly from the command line:
unzip ~/Downloads/filename.zip -d ~/Downloads
Step 4:
Step 3 will likely fail. Run the zip command to attempt to repair any corruption and salvage the contents of the archive (again, replace filename.zip with actualname.zip):
zip -FF ~/Downloads/filename.zip --out ~/Downloads/Repairedversion.zip
If it executes cleanly, you'll be directly returned to your prompt. Quit Terminal. Navigate to your Downloads folder and double click Repairedversion.zip- it should unzip without issue.
Alternatively, it may not exit cleanly. If you're presented with
Is this a single-disk archive? (y/n):
Hit the y key. After you're returned to the prompt, again attempt to open Repairedversion.zip from your Downloads folder. If you're still unable to open it, comment below with the warning(s) received from the command. If you've reached this point though, it's likely that the file is irreparably damaged.
zip warning: no end of stream entry found: _file_inside_archive_zip warning: rewinding and scanning for later entriesIs there anything else that can be done to recover the archive's contents?
– HGDev Jun 17 '15 at 00:59The -F option can be used if some portions of the archive are missing, but requires a reasonably intact central directory. The input archive is scanned as usual, but zip will ignore some problems. The resulting archive should be valid, but any inconsistent entries will be left out. When doubled as in -FF, the archive is scanned from the beginning and zip scans for special signatures to identify the limits between the archive members. If the archive is too damaged or the end has been truncated, you must use -FF.Read the link for more. – njboot Dec 02 '17 at 02:39I had password protected zip.
– avisheks Apr 03 '18 at 04:07diskutilno longer allows you to repair permissions – Adam_G Aug 02 '18 at 16:23