Incompatible Archive WordPress Fix

The ‘Incompatible Archive Error’ happens after updating to WordPress 6.4.3. Especially for those using MacOS to compress their plugin zip archives for upload.

The core of the problem lies in the way MacOS compresses zip files and how WordPress 6.4.3 interprets them upon upload. Recent security enhancements aimed at tightening up the upload process inadvertently introduced challenges for MacOS compressed zip files, leading to the dreaded ‘Incompatible Archive’ error message. Similar issues previously affected WordPress and WP-CLI and the behaviour ties back to PHP’s libzip version discrepancies. You can read about the bug here.

Solution: Use the MacOS Command Line for Compression

Instead of using the MacOS right-click ‘Compress’ option, compress your plugin folder using the Terminal.

zip -r my-plugin.zip my-plugin/