XLSX Dynamic Report Builder

Programmatically build dynamic Excel reports with multi-level merged headers, grouped subtotal, and dynamic columns

Build complex report layouts from JSON data.

  • Multi-level merged headers by header group config
  • Dynamic column sets for dimensions and metrics
  • Grouped subtotal rows
  • Optional grand total row

Example Results

1 examples

Build Grouped Dynamic Report

Build a dynamic report with merged multi-level headers, grouped subtotals, and grand total

xlsx-dynamic-report-builder-example1.xlsx View File
View input parameters
{ "dataJson": "[\n {\n \"region\": \"APAC\",\n \"dept\": \"Sales\",\n \"revenue\": 12000,\n \"cost\": 7200,\n \"profit\": 4800\n },\n {\n \"region\": \"APAC\",\n \"dept\": \"Ops\",\n \"revenue\": 8000,\n \"cost\": 5200,\n \"profit\": 2800\n },\n {\n \"region\": \"EMEA\",\n \"dept\": \"Sales\",\n \"revenue\": 15000,\n \"cost\": 8600,\n \"profit\": 6400\n },\n {\n \"region\": \"EMEA\",\n \"dept\": \"Ops\",\n \"revenue\": 9000,\n \"cost\": 5700,\n \"profit\": 3300\n }\n]", "groupBy": "region", "fixedColumns": "region,dept", "valueColumns": "revenue,cost,profit", "headerGroupsJson": "{\n \"Organization\": [\n \"region\",\n \"dept\"\n ],\n \"Financials\": [\n \"revenue\",\n \"cost\",\n \"profit\"\n ]\n}", "includeGrandTotal": true, "sheetName": "Dynamic Report" }

Key Facts

Category
Conversion & Encoding
Input Types
textarea, text, checkbox
Output Type
file
Sample Coverage
4
API Ready
Yes

Overview

The XLSX Dynamic Report Builder allows you to transform raw JSON data into professional, structured Excel reports featuring multi-level merged headers, automated subtotaling, and custom column grouping.

When to Use

  • When you need to convert flat JSON datasets into formatted reports with hierarchical headers.
  • When you require automatic subtotal calculations based on specific regional or departmental groupings.
  • When you want to generate consistent, multi-column financial or operational summaries from raw data inputs.

How It Works

  • Paste your raw data in JSON format into the Data JSON field.
  • Define your grouping logic and column structure using the Group By and Dimension Columns fields.
  • Map your metrics and organize headers using the Header Groups JSON configuration.
  • Generate and download your formatted XLSX file with optional grand totals included.

Use Cases

Generating monthly financial performance reports from raw database exports.
Creating regional sales summaries with grouped subtotals for management review.
Building operational dashboards that require multi-level header categorization.

Examples

1. Regional Financial Summary

Financial Analyst
Background
An analyst needs to convert a flat JSON export of global sales into a structured report grouped by region.
Problem
Manual grouping and subtotaling in Excel is error-prone and time-consuming for large datasets.
How to Use
Input the JSON data, set 'region' as the group, and define 'revenue', 'cost', and 'profit' as metric columns.
Example Config
groupBy: 'region', valueColumns: 'revenue,cost,profit', includeGrandTotal: true
Outcome
A clean Excel file with regional subtotals and a grand total row, organized under 'Organization' and 'Financials' headers.

Try with Samples

json, xlsx, xls

Related Hubs

FAQ

Can I group data by multiple levels?

Yes, you can specify multiple columns in the 'Group By' field to create nested subtotal structures.

How do I create merged headers?

Use the 'Header Groups JSON' field to map specific columns under a shared parent header name.

Is a grand total row mandatory?

No, you can toggle the 'Include Grand Total' checkbox to enable or disable the final summary row.

What input format is required?

The tool requires a valid JSON array of objects, where each object represents a row of data.

Can I name the output sheet?

Yes, use the 'Sheet Name' field to define a custom title for your generated Excel worksheet.

API Documentation

Request Endpoint

POST /en/api/tools/xlsx-dynamic-report-builder

Request Parameters

Parameter Name Type Required Description
dataJson textarea Yes -
groupBy text No -
fixedColumns text No -
valueColumns text No -
headerGroupsJson textarea No -
includeGrandTotal checkbox No -
sheetName text No -

Response Format

{
  "filePath": "/public/processing/randomid.ext",
  "fileName": "output.ext",
  "contentType": "application/octet-stream",
  "size": 1024,
  "metadata": {
    "key": "value"
  },
  "error": "Error message (optional)",
  "message": "Notification message (optional)"
}
File: File

AI MCP Documentation

Add this tool to your MCP server configuration:

{
  "mcpServers": {
    "elysiatools-xlsx-dynamic-report-builder": {
      "name": "xlsx-dynamic-report-builder",
      "description": "Programmatically build dynamic Excel reports with multi-level merged headers, grouped subtotal, and dynamic columns",
      "baseUrl": "https://elysiatools.com/mcp/sse?toolId=xlsx-dynamic-report-builder",
      "command": "",
      "args": [],
      "env": {},
      "isActive": true,
      "type": "sse"
    }
  }
}

You can chain multiple tools, e.g.: `https://elysiatools.com/mcp/sse?toolId=png-to-webp,jpg-to-webp,gif-to-webp`, max 20 tools.

If you encounter any issues, please contact us at [email protected]