Solutions for the Error “Class ‘ZipArchive’ not found”

- Andrés Cruz

En español

The “Class ‘ZipArchive’ not found” error occurs when we do not have the zip extension enabled or installed; Let's see how we can solve the problem.

Laragon

In Laragon on Windows it is as simple as going to extensions and enabling zip:

 

PHP extension zip

Other systems

On other systems, check if the zip Extension is Enabled:
Open the php.ini file in a text editor.
Find the following line:

;extension=zip

Remove the semicolon at the beginning of the line to enable the extension:

extension=zip

Save the changes and restart your web server and/or PHP.
In Linux environments, you can run the following command in the terminal to install the zip extension:

sudo apt-get install php-zip

Restart your web server and/or PHP.

Andrés Cruz

Develop with Laravel, Django, Flask, CodeIgniter, HTML5, CSS3, MySQL, JavaScript, Vue, Android, iOS, Flutter

Andrés Cruz In Udemy

I agree to receive announcements of interest about this Blog.