Skip to main content
Early access — new tools and guides added regularly
🟡 AI-Assisted Business Ops — Guide 16 of 16
View track
>_ claude codeAdvanced35 min

Executive Reporting Automation

Build an executive reporting system that collects KPIs from multiple sources, generates narrative summaries, and delivers polished reports on schedule.

What you will build
An executive reporting platform with KPI aggregation, narrative generation, and scheduled distribution

Why executive reporting is different

Executive reports are not dashboards. A dashboard shows data. An executive report tells a story — what happened, why it matters, and what we should do about it. Executives have limited time and need to make decisions quickly. A 50-page data dump is useless. A 2-page summary with clear insights and recommendations is invaluable. The key differences: executive reports are narrative-driven (text with supporting charts, not charts with supporting text), they compare against targets (not just showing actuals but showing performance against plan), they highlight exceptions (what deviated from expectations, both good and bad), and they end with recommended actions. Ask Claude Code: Create a Next.js project with TypeScript, Tailwind, and Prisma for an executive reporting platform. Define the database schema. KPI (id, name, description, category as revenue or customers or product or operations or financial, unit as currency or percentage or number or duration, targetValue for the current period, warningThreshold, criticalThreshold, dataSource describing where the value comes from, calculationMethod as direct or calculated with formula). KPIValue (id, kpiId, value as float, period as the reporting period in YYYY-MM format, collectedAt, source). Report (id, title, period, type as weekly or monthly or quarterly or board, status as draft or review or final or distributed, createdAt, distributedAt optional, recipients as JSON array of emails, sections as JSON containing the structured report content). ReportTemplate (id, name, type, sections as JSON defining the report structure and which KPIs to include in each section). Seed with 20 KPIs across all categories, 12 months of historical values, and 2 report templates (monthly executive summary and quarterly board report).

KPI collection from multiple sources

Executive reports aggregate data from across the business. Revenue comes from the payment system, customer metrics from the product database, operational data from internal tools, and financial data from the accounting system. Ask Claude Code: Create a KPI collection framework at src/lib/kpi-collector.ts. Define collector functions for each data source. Revenue collectors: Monthly Recurring Revenue (count active subscriptions multiplied by their price), Annual Recurring Revenue (MRR times 12), Revenue Growth Rate (this month MRR divided by last month MRR minus 1, as a percentage), and Average Revenue Per Account (total MRR divided by customer count). Customer collectors: Total Customers, New Customers This Period, Customer Churn Rate (customers lost divided by customers at start of period), and Net Revenue Retention (revenue from existing customers this period divided by their revenue last period — includes upgrades and downgrades). Product collectors: Daily Active Users (average over the period), Feature Adoption Rate (users who used key features divided by total users), and Support Ticket Volume. For development, simulate these with sample data. Ask Claude Code: Create mock data sources that return realistic KPI values with appropriate trends. Revenue should grow 5 to 10 percent month-over-month. Customer count should grow but with some churn. Product metrics should show seasonal patterns. Build an automated collection pipeline. Ask Claude Code: Create a cron job that runs on the first of each month. For each KPI, call the appropriate collector, store the value in KPIValue, compare to the target and previous period, and flag any KPIs that are below the warning threshold. After collection, trigger the report generation process. Add a manual entry interface for KPIs that cannot be auto-collected. Ask Claude Code: Create a KPI entry page where team leads input their metrics: finance enters cash position and burn rate, HR enters headcount and open positions, and sales enters pipeline value and deal count. Show which KPIs are missing for the current period and send reminders to the responsible people. Common error: KPI values must be point-in-time snapshots, not running calculations. If MRR is 50,000 on January 1st and 55,000 on February 1st, store both values. Do not recalculate January's value later — the historical record must reflect what was true at the time.

Narrative report generation

The most valuable part of an executive report is the narrative — the human-readable summary that explains what the numbers mean. Ask Claude Code: Create a narrative generator at src/lib/narrative.ts. For each KPI, generate a contextual sentence based on its value relative to the target and the previous period. The generator should produce four types of statements. Achievement: MRR reached 55,000 pounds, exceeding the target of 52,000 by 5.8 percent. This represents 10 percent growth from last month's 50,000. Warning: Customer churn rate increased to 4.2 percent, above the 3.5 percent target. This is up from 3.1 percent last month and represents the loss of 12 customers. Trend: Daily active users averaged 2,340, continuing the upward trend that started in September. At this growth rate, we expect to reach 3,000 by March. Context: Support ticket volume increased 25 percent to 180 tickets, correlating with the v2.5 release on November 15th. Ticket volume typically normalises within 2 weeks of a major release. Build section-level narratives. Ask Claude Code: Group KPIs into report sections (Revenue, Customers, Product, Operations) and generate a paragraph for each section that weaves the individual KPI narratives into a coherent story. The section narrative should: lead with the most important KPI, provide context for why metrics changed, highlight connections between metrics (churn increased because of the pricing change last month, which also drove MRR growth from upgrades), and end with a forward-looking statement or recommendation. Generate the executive summary. Ask Claude Code: Create a function that reads all section narratives and produces a 3 to 4 sentence executive summary. The summary should answer: how did we perform overall this period? What was the biggest win? What is the biggest concern? What is the recommended action? Example: November was a strong growth month with MRR exceeding target by 5.8 percent and 45 new customers acquired. Customer churn increased slightly to 4.2 percent, primarily among customers on the legacy pricing plan. We recommend accelerating the migration of legacy customers to the new pricing structure. Focus next month on reducing churn through the retention campaign launching December 1st. Common error: generated narratives must be factually accurate. Every number in the text must match the underlying data exactly. Build a validation step that cross-references the narrative text against the KPI values and flags any discrepancies.

Report design and formatting

An executive report must be visually polished — it represents the quality of your leadership team's thinking. A poorly formatted report undermines confidence in the content. Ask Claude Code: Create a report renderer at src/lib/report-renderer.ts. The renderer takes the structured report content (sections, narratives, KPI values) and produces a polished PDF. Define the report layout. Page 1 — Executive Summary: the company logo, report title (Monthly Executive Report — November 2024), the executive summary paragraph, and a KPI dashboard strip showing the 6 most important metrics as compact cards with current value, target, and trend arrow. Pages 2-3 — Detailed Sections: each section (Revenue, Customers, Product, Operations) gets a quarter to half page with: a section heading, the narrative paragraph, and one supporting chart (revenue trend line, customer growth bar chart, etc.). Final Page — Appendix: a data table with all KPIs showing the current value, previous period value, change percentage, and target. Build the charts. Ask Claude Code: Create chart generation functions using SVG (embedded in the PDF). Revenue chart: a line chart showing monthly revenue for the last 12 months with the target line overlaid. Customer chart: a stacked bar chart showing new customers and churned customers per month with a net growth line. Product chart: a multi-line chart showing DAU, WAU, and MAU trends. Add colour coding consistent with the rest of the report — use the company brand colours for data series and red for below-target indicators. Add a comparison overlay. Ask Claude Code: For each chart, add an option to overlay the same period from the previous year. This year-over-year comparison is especially valuable for boards and investors. Show this year's data as solid lines and last year's as dashed lines. Add annotations for significant events (product launches, pricing changes, market events) as vertical markers on the timeline. Build alternative output formats. Ask Claude Code: In addition to PDF, generate: an HTML version for email (inline CSS for email client compatibility), a PowerPoint version for board presentations (using pptxgenjs), and a Markdown version for internal wikis or documentation. Each format should contain the same content adapted to the medium — the email version should be scannable with a View Full Report link. Common error: charts in PDFs must be embedded as vectors (SVG), not raster images (PNG). Vector charts stay crisp at any zoom level and print cleanly. Raster charts become blurry when the reader zooms in, which executives inevitably do when reviewing numbers.

Report review workflow and versioning

Executive reports go through a review cycle before distribution. The CEO does not send the board a first draft — it goes through fact-checking, narrative refinement, and formatting review. Ask Claude Code: Create a report review workflow at src/lib/review.ts. The workflow has these stages. Draft: the report is auto-generated from collected KPIs and narrative templates. The report creator reviews the generated content, adds commentary where the automated narrative misses context, and adjusts any charts or formatting. Review: the report is sent to designated reviewers (typically the CFO, COO, or department heads). Each reviewer can: approve their section, suggest edits (tracked as comments), or flag factual errors. The system shows which sections have been reviewed and approved. Final: all sections are approved. The report is locked for editing. The only remaining action is distribution. Distributed: the report is sent to recipients. The distribution is logged with timestamp and recipient list. Build the review interface. Ask Claude Code: Create a review page at src/app/reports/[id]/review/page.tsx. Show the report in its final format (PDF preview) with a comment sidebar. Reviewers click on any section to add a comment. Comments are threaded — the editor can respond to a comment, make the requested change, and mark the comment as resolved. Show a review progress bar: 3 of 5 sections approved. Add version tracking. Ask Claude Code: Every edit creates a new version of the report. Store version history with: the version number, who made the change, when, and what changed (a diff of the report content). Allow reverting to any previous version. Show a version comparison view: select two versions and see what changed between them (additions highlighted in green, deletions in red). This audit trail is especially important for board reports where accuracy has legal implications. Add a report template system. Ask Claude Code: Create configurable templates for different report types. The monthly executive summary template has 4 sections and 12 KPIs. The quarterly board report template has 8 sections, 25 KPIs, and additional appendices for financial statements and market analysis. The weekly team update template has 3 sections focused on operational metrics. Let users create custom templates by selecting which sections and KPIs to include. Common error: report review cycles can drag on if there is no deadline pressure. Set an automatic distribution deadline — the report must be distributed by a specific date. Show a countdown timer during the review phase. If the deadline is approaching and sections are not approved, escalate with increasingly urgent notifications.

Scheduled distribution and deployment

The final step is getting the report to the right people at the right time, consistently and reliably. Ask Claude Code: Build a report distribution system at src/lib/distribution.ts. For each report type, configure: the recipient list (board members, leadership team, department heads, investors), the distribution schedule (monthly reports go out by the 5th, quarterly reports by the 15th after quarter end), the format preference per recipient (some prefer PDF attachment, others prefer the HTML email with a link to the full report), and the delivery channel (email for external recipients, email plus Slack notification for internal recipients). Automate the distribution. Ask Claude Code: Create a distribution cron job. On the configured distribution day, check if the report is in Final status. If yes, generate the output in each required format, send personalised emails to each recipient (Dear Board Member Name, please find attached the Q3 Executive Report), post a notification in the leadership Slack channel with a link to the report, and log the distribution in the database. If the report is not in Final status on distribution day, send an alert to the report owner: the monthly report has not been finalised and is due for distribution today. Build a report archive and search. Ask Claude Code: Create a report library at src/app/reports/page.tsx. Show all past reports organised by type and period. Each report links to its PDF and shows: the distribution date, recipient count, and key metrics for quick scanning (MRR, customer count, and growth rate as inline numbers). Add full-text search across all past reports — find every report that mentioned a specific customer, product, or metric. Add a board portal. Ask Claude Code: Create a secure, read-only portal for board members and investors at src/app/portal/page.tsx. After authentication, board members see: the latest reports for their configured report types, a KPI dashboard showing real-time metrics (not just the monthly snapshot), document repository (board minutes, financial statements, strategy documents), and a meeting calendar showing upcoming board meetings. Add read tracking: log when each recipient opens the report. Show the report creator which recipients have read the report and which have not. This is useful for following up before board meetings. Deploy the executive reporting platform. Ask Claude Code: Configure production deployment on Vercel with a PostgreSQL database. Set up the KPI collection cron (1st of each month), the distribution cron (5th for monthly, 15th after quarter end for quarterly), and the reminder crons (3 days before distribution deadline). Configure email sending via Resend with the company's sending domain for professional appearance. Test the complete cycle: collect KPIs, generate a report, review and approve it, distribute to recipients, and verify delivery. The executive reporting platform is complete — transforming a manual, inconsistent process into an automated, reliable system that keeps leadership informed with accurate, polished reports delivered on schedule.

Related Lesson

Executive Communication

This guide is hands-on and practical. The full curriculum covers the conceptual foundations in depth with structured lessons and quizzes.

Go to lesson