Merge Excel Files - Consolidation for Zapier
PDF4me Merge Excel Files eliminates the tedious task of manually combining spreadsheets. Whether you're consolidating monthly reports from different departments, merging quarterly data files, or assembling customer records from multiple sources, this action intelligently combines worksheets while handling duplicate sheet names automatically. Control exactly which sheets to include from each file, specify the merge order, and output in Excel, PDF, or CSV format. Perfect for creating master reports, combining financial data, or assembling comprehensive datasets from distributed files.
Authenticating Your API Request
To access the PDF4me Web API through Zapier, every request must include proper authentication credentials. Authentication ensures secure communication and validates your identity as an authorized user, enabling seamless integration between your Zapier workflows and PDF4me's powerful Excel file merging services.

Configuration at a Glance
The screenshot above shows merging 2 Excel files: File1 (Sheet2, Sheet1) and File2 (Sheet5), with Output FileName and Output Format set. Sort Position controls merge order.
mergefile32
XLSX
2
Map from previous steps
Sheet1, Sheet2 / Sheet5
:::tip Map File1, File2, etc. from previous steps Use the + button next to File1, File2, and corresponding File Name1, File Name2 fields to map from earlier Zap steps. Set Number of files to match how many files you are merging. Each file must provide full content. :::
:::warning File: (Exists but not shown) If you see "File: (Exists but not shown)" and get errors, select the option that provides the full file content instead. See Zapier & Power Automate Tips for details. :::
Key Features
- Multiple File Merging: Combine 2+ Excel files into one workbook (Number of files)
- Selective Worksheets: Worksheets To Merge1, Worksheets To Merge2—choose sheets per file or leave empty for all
- Sort Control: Sort Position1, Sort Position2—lower numbers merged first
- Output Format: XLSX, XLS, PDF, or CSV
- Duplicate Name Handling: Duplicate worksheet names automatically renamed with suffixes
Parameters
Complete list of parameters for the Merge Files action. Parameter names match the Zapier configuration UI. The UI shows File1, File2, etc.—one set per file based on Number of files.
- Set Output FileName (merged file name, no extension) and Output Format (XLSX, etc.)
- Set Number of files (e.g., 2 for File1 + File2)
- Map File1, File Name1; File2, File Name2; etc.
- Optionally set Worksheets To Merge1, Worksheets To Merge2 (or leave empty for all sheets)
- Set Sort Position1, Sort Position2 for merge order (1, 2, 3...)
Important: Parameters marked with an asterisk (***) are required. Use the + button to map file content and names. Duplicate worksheet names are automatically renamed (e.g., Summary_1, Summary_2).
| Parameter | Type | Description | Example |
|---|---|---|---|
| Output FileName*** | String | Merged output filename (no extension). Extension added from Output Format | mergefile32 |
| Output Format*** | String | Output format—XLSX, XLS, PDF, or CSV | XLSX |
| Number of files*** | Integer | Count of files to merge. Determines File1, File2, ... slots | 2 |
| File1*** | File | First Excel file—map from previous step | [2. File from Step 2] |
| File Name1*** | String | First file filename—map from previous step (e.g., Full File Name) | add_header_sample_file.xlsx |
| Sort Position1 | Integer | Merge order for first file. Lower = merged earlier | 1 |
| Worksheets To Merge1 | Array | Sheets to include from File1. Empty = all sheets. Use + to add each sheet | Sheet1, Sheet2 |
| File2*** | File | Second Excel file—map from previous step | [2. File from Step 2] |
| File Name2*** | String | Second file filename | abc.xlsx |
| Sort Position2 | Integer | Merge order for second file | 2 |
| Worksheets To Merge2 | Array | Sheets to include from File2. Empty = all sheets | Sheet5 |
Merging more than 2 files
Set Number of files to 3, 4, etc. Zapier will show File3, File Name3, Sort Position3, Worksheets To Merge3, and so on. Map each file and set sort positions for merge order.
Output
The PDF4me Merge Excel Files action returns the merged Excel file for use in subsequent Zap steps. The output format is common across PDF4me Excel file-returning actions in Zapier.
Key output fields (map these to your next step)
API endpoint to download the merged Excel file. Map this to the next step's file input.
Generated URLs follow this format (example—not a working link):
api.pdf4me.com/Zapier/GetDocument?d=...Alternative download URL with the filename in the path.
api.pdf4me.com/Zapier/GetAltDocument/.../mergefile32.xlsxUse for naming or passing metadata to the next step.
Complete output structure
- Table
- JSON
- Zap Integration
All output fields (Zapier Test/Output panel)
| Parameter | Type | Description |
|---|---|---|
| Job Id | String | Unique identifier for the Zapier job execution |
| File Url | URL | API endpoint to download the merged Excel file |
| Alternate File Url | URL | Alternate download URL with filename in path |
| File Name | String | Base filename without extension |
| File Extension | String | File extension (e.g., .xlsx) |
| Full File Name | String | Complete filename with extension |
| Document Id | String | Unique identifier for the processed document |
| File Size | Number | Size of the output file in bytes |
| Doc Text | String | Extracted text (typically empty for Excel operations) |
Example JSON output
The action generates unique URLs when it runs. Values below show the structure:
{
"Job Id": "969f2da3-f10a-49bf-b084-6fc4759991ec",
"File Url": "api.pdf4me.com/Zapier/GetDocument?d=...",
"Alternate File Url": "api.pdf4me.com/Zapier/GetAltDocument/.../mergefile32.xlsx",
"File Name": "mergefile32",
"File Extension": ".xlsx",
"Full File Name": "mergefile32.xlsx",
"Document Id": "07386627-184a-44b2-a040-5ea2712a4bc5",
"File Size": 212764,
"Doc Text": ""
}
Map File Url or Alternate File Url to the next step's file input.
Using output in subsequent steps
- File Url → Primary choice for file input (Drive, Dropbox, Email attachments)
- Alternate File Url → Use when the app expects filename in the URL
- Full File Name → Use when the next step needs the filename
Common downstream actions: Upload to Google Drive/Dropbox, attach to email, chain to other PDF4me Excel actions.
:::info Same output for file-returning Excel actions This output structure is shared across Merge Files, Add Rows, Delete Rows, and other PDF4me Excel actions that return a file. The URLs are temporary—use them in the next step before they expire. :::
Scenario Examples
The PDF4me Merge Excel Files action in Zapier provides comprehensive scenario templates designed for real-world file consolidation needs:
- Monthly Consolidation
- Regional Aggregation
- Quarterly Archive
Automated Monthly Department Report Consolidation Workflow
Consolidate multiple department reports into one executive workbook automatically:
Complete Scenario Steps:
- Trigger: Monthly consolidation scheduled on first day of month at 8 AM
- List Department Folders: Get all department report folders from Google Drive
- Iterate Departments: Loop through each department folder
- Get Department Report: Retrieve monthly report Excel from each folder
- Set Merge Parameters: Output FileName = "Monthly_Consolidated", Output Format = XLSX, Number of files = 10
- Map Files: Map File1–File10 and File Name1–File Name10 from each department
- Set Sort Order: Sort Position1 = 1, Sort Position2 = 2, ... for department sequence
- Merge All Reports: Combine all department reports into one workbook
- Upload Result: Map File Url from output to executive Google Drive
- Email Leadership: Send notification with consolidated report to C-suite
Business Benefits:
- Consolidates 10+ department reports monthly automatically
- Maintains department worksheet separation in consolidated workbook
- Automatic conflict resolution handles duplicate worksheet names
- Reduces manual consolidation time from 3 hours to 5 minutes
Automated Regional Sales Report Aggregation Workflow
Aggregate regional sales files with selective worksheet merging:
Complete Scenario Steps:
- Trigger: Weekly regional consolidation scheduled every Monday at 6 AM
- Get Regional Files: Retrieve sales reports from 5 regional folders in Dropbox
- Set Merge Parameters: Output FileName = "Weekly_Regional", Output Format = XLSX, Number of files = 5
- Map Regional Files: Map File1–File5 and File Name1–File Name5
- Select Worksheets: Set Worksheets To Merge1 = Sheet1, Sheet2 for each region (or "Summary,Details")
- Set Regional Order: Sort Position1 = 1 (West), Sort Position2 = 2 (Central), etc.
- Merge: Duplicate worksheet names renamed (Summary_1, Summary_2, etc.)
- Upload Result: Map File Url from output to sales team Google Drive
- Email Sales Leadership: Send weekly aggregated report to sales VP
Business Benefits:
- Aggregates 5 regional reports weekly automatically
- Selective worksheet merging reduces file size by 60%
- Sort control ensures consistent regional order
- Eliminates manual copy-paste saving 2 hours weekly
Automated Quarterly Archive PDF Generation Workflow
Consolidate quarterly files and convert to PDF for compliance archival:
Complete Scenario Steps:
- Trigger: Quarterly archival scheduled on first day after quarter end
- Get Month Files: Retrieve Jan, Feb, Mar Excel files from SharePoint
- Set Merge Parameters: Output FileName = "Q1_2024_Archive", Output Format = PDF, Number of files = 3
- Map Files: Map File1–File3 and File Name1–File Name3 (Jan, Feb, Mar)
- Set Chronological Order: Sort Position1 = 1 (Jan), Sort Position2 = 2 (Feb), Sort Position3 = 3 (Mar)
- Merge: Combine all worksheets from all three months (leave Worksheets To Merge empty for all)
- Upload Result: Map File Url from output to Azure Blob
- Create Archive Index: Add entry to compliance index with quarter and location
- Email Compliance: Send archival confirmation to compliance officer
Business Benefits:
- Archives 4 quarterly consolidated reports annually
- PDF format ensures unmodifiable compliance records
- All monthly worksheets preserved in single archive file
- Reduces manual archival process from 4 hours to 10 minutes
Industry Use Cases & Applications
- Finance & Accounting
- Sales & Marketing
- Human Resources
- Operations & Supply Chain
- Period Consolidation: Merge monthly P&L, balance sheet, and cash flow files into quarterly workbook
- Entity Rollup: Combine subsidiary financial statements into consolidated reporting workbook
- Budget Aggregation: Merge departmental budget files into master company budget workbook
- Audit File Assembly: Consolidate working paper files from multiple audit areas into audit file
- Variance Reporting: Merge actual results with budget/forecast files for variance analysis workbook
- Regional Sales Consolidation: Merge regional sales reports into national sales workbook with regional tabs
- Channel Performance: Combine direct, partner, and online channel reports into omnichannel workbook
- Campaign Aggregation: Merge individual campaign results into comprehensive marketing performance workbook
- Territory Reporting: Consolidate territory manager reports into regional VP reporting workbook
- Quarterly Business Review: Merge monthly sales files into quarterly review workbook for QBR meetings
- Payroll Consolidation: Merge location/division payroll files into master payroll workbook
- Benefits Enrollment: Combine benefit election files from multiple periods into annual enrollment workbook
- Headcount Reporting: Merge departmental headcount files into company-wide headcount report
- Training Records: Consolidate training completion files by department into master training log
- Performance Review: Merge individual review files into company-wide performance management workbook
- Multi-Site Operations: Merge site operational reports into corporate operations workbook
- Inventory Consolidation: Combine warehouse inventory files into master inventory workbook
- Production Aggregation: Merge plant production reports into manufacturing performance workbook
- Quality Reporting: Consolidate QC inspection files from multiple lines into quality dashboard workbook
- Logistics Consolidation: Merge carrier performance files into consolidated logistics reporting workbook