Eazip.js
EazipGitHub
Concepts

Multi-ZIP splitting

Understand how maxZipSizeBytes divides large output into predictable ZIP parts.

Set maxZipSizeBytes when one large download would be inconvenient or exceed a downstream limit:

const result = await createZip({
  files,
  zipName: 'export.zip',
  maxZipSizeBytes: 1_000_000_000,
});

result.downloadAll();

One entry per output part appears in result.zips, or in task.zips for React.

A best-effort limit

Eazip estimates compressed size before writing each entry. A ZIP part may exceed the limit when one source file is larger than the configured cap.

How are files assigned to parts?

Eazip preserves input order. Before adding each file it estimates whether the file still fits the current part, and starts the next part when it does not.

A single ZIP entry is never divided across parts. An oversized file therefore gets its own oversized ZIP instead of failing the export.

How are parts named?

  • One output keeps the requested name, such as export.zip.
  • Multiple outputs use export_part01.zip, export_part02.zip, and so on.
  • Part numbers expand beyond two digits when needed.

Does this work with Local and Cloud?

Yes. The option and result shape are identical; Local splits in the browser, Cloud splits on the server.

Local archives use ZIP64, so large entry counts and offsets do not hit legacy ZIP limits. Modern operating systems and archive tools support ZIP64.

See Create multi-GB ZIP archives with JavaScript for a complete Cloud workflow.