Skip to main content

Reusable subworkflow zip multiple files dynamically (compress)

Workflow preview

Workflow preview
100%
Reusable subworkflow zip multiple files dynamically (compress) preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Zip Multiple Files Dynamically This template enables you to dynamically bundle multiple files into a ZIP archive. Designed to be used as a Subworkflow , it’s modular, flexible, and easy to integ...

Best for

  • File Management automation workflows
  • intermediate n8n builders looking for reusable templates

Tools used

n8n-nodes-base.executeworkflowtrigger, n8n-nodes-base.compression, n8n-nodes-base.stickynote, n8n-nodes-base.set, n8n-nodes-base.code

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Simon.

Original n8n.io source

1.1 Workflow description

Title
Reusable subworkflow zip multiple files dynamically (compress)
Workflow name
Reusable subworkflow zip multiple files dynamically (compress)

πŸ“¦ Zip Multiple Files Dynamically

This template enables you to dynamically bundle multiple files into a ZIP archive. Designed to be used as a Subworkflow, it’s modular, flexible, and easy to integrate into various workflows. The output is a single ZIP file with a name that includes the current date, time, and fileName.

Shoutout: Code from: Tom (mutedjam)


πŸ‘€ Who is this for?

This workflow is perfect for:

  • πŸš€ Businesses automating file archiving tasks.
  • πŸ’» Developers managing files programmatically.
  • πŸ“‚ Anyone needing a reusable solution for bundling files into ZIP archives.

❓ What problem is this workflow solving?

Manually zipping multiple files is:

  • πŸ•’ Time-consuming.
  • πŸ€” Prone to errors.

This workflow automates the process and, as a Subworkflow, ensures:

  • ⚑ Consistent file archiving across different workflows.
  • πŸ› οΈ Reduced manual effort.
  • πŸ“ˆ Streamlined integration into existing automation.

πŸ”§ What this workflow does

  1. πŸ—‚οΈ Dynamically collects binary files from the input.
  2. πŸ“¦ Bundles them into a single ZIP archive.
  3. πŸ•’ Names the ZIP file with the current date, time, and a customizable fileName.
  4. βœ… Outputs the ZIP file, ready for storage or further processing.

βš™οΈ Setup

  1. πŸ”— Add this Subworkflow to your existing workflows.
  2. πŸ“₯ Pass the binary files as input to the Subworkflow.
  3. ▢️ Call the Subworkflow to generate a ZIP file.

πŸ› οΈ How to customize this workflow to your needs

  • 🌐 File Sources: Adjust the input nodes in your parent workflow to connect to your preferred file sources.
  • πŸ“ File Naming: Customize the logic for the output fileName in the Subworkflow.
  • πŸš€ Additional Use Cases: Use this Subworkflow in various scenarios, such as:
    • βœ‰οΈ Sending ZIP files via email.
    • ☁️ Uploading ZIP files to cloud storage.
    • πŸ”„ Triggering further automation.

πŸŽ‰ Why use this as a Subworkflow?

Instead of building a fixed ZIP functionality for every workflow, this template offers a reusable solution that can be integrated into many different workflows effortlessly. Save time and ensure consistency across your automation projects! πŸ’‘

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Execute Workflow Trigger

Type / Role
n8n-nodes-base.executeWorkflowTrigger - executeWorkflowTrigger
Config choices
Version 1

Block 2 - Compression

Type / Role
n8n-nodes-base.compression - compression
Config choices
Version 1.1

Block 3 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 4 - Prepare Output

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 5 - Code Magic

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

3. Summary Table

Workflow Reusable subworkflow zip multiple files dynamically (compress)
Complexity intermediate
Nodes 5
Categories File Management
Author Simon
Published 02 Jan 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/2690/2690.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Reusable subworkflow zip multiple files dynamically (compress) do?

Zip Multiple Files Dynamically This template enables you to dynamically bundle multiple files into a ZIP archive. Designed to be used as a Subworkflow , it’s modular, flexible, and easy to integ...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your File Management use case.