PHPackages                             waithaw/phpzipper - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. waithaw/phpzipper

ActiveLibrary[File &amp; Storage](/categories/file-storage)

waithaw/phpzipper
=================

To zip/unzip files/folders easily

v1.0.1(2y ago)160MITPHPPHP &gt;=7.3

Since Jun 14Pushed 2y ago1 watchersCompare

[ Source](https://github.com/waithawoo/phpzipper)[ Packagist](https://packagist.org/packages/waithaw/phpzipper)[ RSS](/packages/waithaw-phpzipper/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

PHP Zipper
==========

[](#php-zipper)

[![GitHub issues](https://camo.githubusercontent.com/f29cfcab105557a43819371e244da560a9d65fb593086fda0590780e40bc51d9/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732f776169746861776f6f2f7068707a6970706572)](https://github.com/waithawoo/phpzipper/issues)[![GitHub stars](https://camo.githubusercontent.com/e111abcf7cda4cb3d3be45fada65cfeff884231fc6d34c9f9375764277f7469a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f776169746861776f6f2f7068707a6970706572)](https://github.com/waithawoo/phpzipper/stargazers)[![GitHub forks](https://camo.githubusercontent.com/eea0ab03150f719489885310d1ae9be4d006ef0bb5f376186b657c85b8cbb6db/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f776169746861776f6f2f7068707a6970706572)](https://github.com/waithawoo/phpzipper/network)[![GitHub license](https://camo.githubusercontent.com/f61dcd85644443db87ffa13ae56e5366d37cca6b0eb1d0f8a2d1b00e1fa39300/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f776169746861776f6f2f7068707a6970706572)](https://github.com/waithawoo/phpzipper/blob/main/LICENSE)

To zip/unzip files/folders easily including password protected
--------------------------------------------------------------

[](#to-zipunzip-filesfolders-easily-including-password-protected)

Created for easy use to zip/unzip including password protected (using PHP's native ZipArchive class)

- **[Installation](#installation)**
- **[Usage](#usage)**

Installation
------------

[](#installation)

Install this package via [Composer](https://getcomposer.org/).

```
composer require waithaw/phpzipper
```

Usage
-----

[](#usage)

### Create Zip object

[](#create-zip-object)

```
use WaiThaw\PhpZipper\Zip;

$zip = new Zip();
```

### Creating a Zip file from Single file or multiple files with no password

[](#creating-a-zip-file-from-single-file-or-multiple-files-with-no-password)

```
$zip->createFromFiles('backup.zip', $file);
//OR
$zip->createFromFiles('backup.zip', $filelists);
```

### Creating a Zip file from Single file or multiple files with password

[](#creating-a-zip-file-from-single-file-or-multiple-files-with-password)

```
$zip->createFromFiles('backup.zip', $file, 'password');
//OR
$zip->createFromFiles('backup.zip', $filelists, 'password');
```

### Creating a Zip file from a directory including sub directories

[](#creating-a-zip-file-from-a-directory-including-sub-directories)

```
// Without a password
$zip->createFromDir('backup.zip', 'D:\testfolder');
// With a password
$zip->createFromDir('backup.zip', 'D:\testfolder', 'password');
```

### Extracting a simple or password-protected zip file

[](#extracting-a-simple-or-password-protected-zip-file)

```
// Extracting a simple zip file.
$zip->extractTo('backup.zip', 'D:\outputpath');
//Extracting a password-protected zip file
$zip->extractTo('backup.zip', 'D:\outputpath', 'password');
```

### Downloading zip files

[](#downloading-zip-files)

```
// You can download the zip file at once archiving.
$zip->createFromFiles('backup.zip', $file)->download();
$zip->createFromDir('backup.zip', 'D:\testfolder')->download();

// And you can also delete the zip file after downloaded, by passing ‘delete’ string in download() method.
$zip->createFromFiles('backup.zip', $file)->download('delete');
$zip->createFromDir('backup.zip', 'D:\testfolder')->download('delete');
```

Security
--------

[](#security)

If you discover any security related issues, please email them to  instead of using the issue tracker.

License
-------

[](#license)

The MIT License (MIT). Please see the [License File](LICENSE) for more information.

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~125 days

Total

2

Last Release

943d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1e4d5c98c73b03e0146a13de94e680697e25f1d2aac42ee5219f094412a89ba0?d=identicon)[waithawoo](/maintainers/waithawoo)

---

Top Contributors

[![waithawoo](https://avatars.githubusercontent.com/u/42320296?v=4)](https://github.com/waithawoo "waithawoo (14 commits)")

---

Tags

phpphp-archivephp-unzipphp-zipphparchivephpzipphpzipperunzipzipzip-helperziparchivezipper

### Embed Badge

![Health badge](/badges/waithaw-phpzipper/health.svg)

```
[![Health](https://phpackages.com/badges/waithaw-phpzipper/health.svg)](https://phpackages.com/packages/waithaw-phpzipper)
```

###  Alternatives

[knplabs/gaufrette

PHP library that provides a filesystem abstraction layer

2.5k39.8M123](/packages/knplabs-gaufrette)[google/cloud-storage

Cloud Storage Client for PHP

34390.8M125](/packages/google-cloud-storage)[illuminate/filesystem

The Illuminate Filesystem package.

15261.6M2.6k](/packages/illuminate-filesystem)[superbalist/flysystem-google-storage

Flysystem adapter for Google Cloud Storage

26320.6M30](/packages/superbalist-flysystem-google-storage)[creocoder/yii2-flysystem

The flysystem extension for the Yii framework

2931.7M62](/packages/creocoder-yii2-flysystem)[flowjs/flow-php-server

PHP library for handling chunk uploads. Works with flow.js html5 file uploads.

2451.6M15](/packages/flowjs-flow-php-server)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
