# FormulaGuard > 100% local, zero-upload Excel formula and workbook change auditor—available as an offline browser PWA, a Node.js CLI (`npx formulaguard`), and an MCP server (`npx -y formulaguard-mcp`). ## Overview FormulaGuard compares baseline and modified spreadsheets (`.xlsx`, `.xlsm`, `.xlsb`, `.xls`, `.ods`) on the user's own machine without uploading workbook contents to remote servers. Built for Mac & Microsoft 365 Business users missing Windows-only Microsoft Spreadsheet Compare, finance teams signing off on model edits, and developers/AI workflows guarding spreadsheets edited by Claude, ChatGPT, or Copilot. ## Core Capabilities - **Silent Formula Freeze Detection**: Flags formulas (`=SUM(...)`, `=INDEX/MATCH`, `=XLOOKUP`) overwritten with typed hardcoded numbers—even when the displayed number did not change. - **Shortened SUM / Aggregate Ranges & New Errors**: Catches truncated formula bounds (`SUM(B2:B50)` -> `SUM(B2:B48)`), formulas repointed to another sheet, newly hidden rows/columns, and new `#REF!`, `#VALUE!`, `#NAME?`, `#DIV/0!` errors. - **Root-Cause vs Cascaded Recalculation Separation**: Traces cell dependencies, workbook/sheet Defined Names, and OOXML Excel Tables (`TableName[Column]`, `[@Column]`) to isolate direct root edits from downstream recalculated totals. - **AI / `openpyxl` Uncached Formula Support**: Distinguishes intact formulas missing `` cached values from deleted formulas. - **2D Smart Align (Rows & Columns)**: Aligns inserted/deleted rows and columns and flags newly inserted adjacent rows/columns omitted from `SUM`/`AVERAGE`/`COUNT` ranges. Column alignment matches header labels (or, without a header row, unchanged cells in the first rows) and pairs the columns between those matches by content. On a sheet without a header row where many values also changed, an inserted column can still be misreported as formulas overwritten. Content pairing needs CLI 0.1.1 or MCP 0.1.2 or later; older npm releases pair unlabelled columns by position. ## Three Ways to Use FormulaGuard 1. **Web App (`https://formulaguard.tabwright.dev/`)**: Drop before/after files directly into the browser (Mac, Windows, Linux). Works offline as an installable PWA after first visit; all workbook parsing and diffing execute in a client-side Web Worker. 2. **CLI (`npx formulaguard`)**: Node 18+ command-line auditor (`npx formulaguard before.xlsx after.xlsx --fail-on critical --markdown` or `npx formulaguard batch `) with deterministic exit codes, so it can run as a step in CI such as a GitHub Actions workflow. 3. **MCP Server (`npx -y formulaguard-mcp`)**: Model Context Protocol server (`snapshot_workbook` + `audit_workbook_changes`) allowing Claude Desktop, Claude Code, and compatible AI agents to verify their own spreadsheet edits before finishing. ## Privacy & Offline Verification - **Workbooks never leave your machine.** Web parsing, SHA-256 hashing, and formula diffing execute inside a local Web Worker; CLI and MCP run locally in Node.js. - Users can verify zero workbook uploads on the Web App by visiting once, disconnecting Wi-Fi (or watching DevTools `F12` Network), and comparing files offline. - Only Pro license activation, periodic ~7-day validation, and deactivation contact `/api/license/` (backed by Creem), sending only the license key with an anonymous activation ID or a random label (never file paths, workbook content, or computer names). ## Pricing & Plan Limits - **Web Free (`$0`)**: Up to **2 worksheets and 500 rows per sheet**; exports a watermarked HTML report listing up to **12 critical or high findings**. - **CLI Free (`$0`)**: Full detection across every worksheet and row, CI exit codes, text, JSON and Markdown output, and an HTML preview report (first 12 critical or high findings, watermarked). - **MCP Free (`$0`)**: Full detection across every worksheet and row, structured results returned to the AI agent, and the same HTML preview report. - **Pro (`$29` one-time payment)**: One license with **5 activations**, shared by the web app, CLI and MCP server (30-day offline grace). Removes the web app's worksheet and row limits, and unlocks unwatermarked HTML reports listing every critical and high finding, multi-tab `.xlsx` diff ledger exports, and custom **Protected Ranges** (`--protect` / `protected_ranges`). - **Size limits (all plans)**: files up to 35 MB in the web app and 50 MB in the MCP server; up to 500,000 parsed cells per workbook. ## Verification & Scope Notes - Built-in demo workbooks on the home page let reviewers verify findings before opening real models; every report prints SHA-256 hashes of both files and serves `Cache-Control: no-transform` with zero analytics or tracking scripts. - Honest scope: compares `.xlsx`, `.xlsm`, `.xlsb`, `.xls`, `.ods` formulas, values, hidden rows/columns, Defined Names, and Structured Tables; does not compare cell styling/formatting or VBA macros. ## Guides & Resources - [FormulaGuard Local Auditor App](https://formulaguard.tabwright.dev/) - [Spreadsheet Compare on a Mac](https://formulaguard.tabwright.dev/spreadsheet-compare-mac) - [Compare Formulas Between Two Excel Files](https://formulaguard.tabwright.dev/compare-excel-formulas) - [Check If ChatGPT or Claude Overwrote Excel Formulas](https://formulaguard.tabwright.dev/check-ai-excel-formulas) - [npm CLI package: formulaguard](https://www.npmjs.com/package/formulaguard) - [npm MCP package: formulaguard-mcp](https://www.npmjs.com/package/formulaguard-mcp) - [Public CLI & MCP Documentation](https://github.com/tomyin1314/formulaguard-action) - Contact: tabwright.dev@gmail.com