Guides: query CSVs and Google Sheets from AI agents and apps
How to let agents and apps query your spreadsheets instead of reading them, step by step.
AI chats and agents
Claude, ChatGPT, Cursor and other MCP clients.
- How to connect Google Sheets to Claude: 5 ways compared (free plan included)Get Google Sheets to Claude on a free or paid plan: upload, Anthropic's Sheets connector, the older Claude for Sheets add-on, Google's Sheets MCP server, open-source MCP servers or a hosted query server, and the setup step by step.
- Google Sheets MCP server: hosted, no Google Cloud setupUse a hosted MCP server for Google Sheets in Claude Code, Cursor and other MCP clients. No service account, no local process.
- ChatGPT MCP: add a custom MCP server (and query a spreadsheet)Add a remote MCP server to ChatGPT from Plugins or developer mode, then let it filter and total a CSV or Google Sheet with exact results.
- CSV and Excel MCP server: query files from Claude, ChatGPT and CursorTurn a CSV or an Excel (.xlsx) file into a hosted MCP server Claude, ChatGPT and Cursor can query, or when a local CSV or Excel MCP server is the better pick.
- ChatGPT and Claude CSV limits: analyze big files without uploading themWhy large CSV uploads fail or give approximate totals in AI chats, and how to let the model query the file instead.
- AI token cost calculator for spreadsheets: what pasting your sheet costs per questionEnter rows and columns to see how many tokens a pasted spreadsheet uses, how much of the context window it fills and what each question costs.
- LLM API pricing comparison: Claude, GPT and Gemini per million tokensInput and output prices and context windows for 11 current Claude, OpenAI and Gemini models, from each vendor's pricing page, and what one spreadsheet question costs on each.
- Why ChatGPT and Claude get spreadsheet totals wrong (and how to get counted answers)Four reasons an AI chat gets a spreadsheet total wrong, what we measured on a 5,000 and a 50,000-row file, and three ways to get counted answers.
- Test an AI data tool on linked sheets: free test set with hand-counted answersThree small linked sheets (orders, customers, regions) with one deliberate missing customer, and the answers counted by hand, to check any AI data tool before you connect real data.
- Budget vs actual: variance formula, report layout and the double-counting trapHow to build and read a budget vs actual report: variance and variance % formulas, SUMIFS in Excel or Google Sheets, why lookups inflate the budget, and asking an AI agent across both sheets.
- Sales data analysis: a worked example with sample data to downloadA sales data analysis example on sample sales data you can download (39 orders, 8 customers): monthly sales, product, region and top customers, every answer, the Excel and Sheets formulas, and three mistakes that skew the numbers.
- Inventory turnover: formula, days of inventory and a worked exampleHow to calculate inventory turnover and days of inventory per product on a real-looking quarter of sales and stock, with dead stock, reorder points, the Excel and Google Sheets formulas, and three mistakes that inflate the ratio.
- AI semantic layer: one definition of revenue across Claude, ChatGPT and CursorHow to make every AI agent use the same definition of revenue: a rules file, dbt, Cube or an AI data layer compared, and the setup for spreadsheet data without a data team.
- GDPR-compliant AI and LLM APIs: the checks, EU data residency and three setupsWhat GDPR asks of an AI assistant or LLM API, where the model runs vs where data is stored (Claude's API has no EU option yet), and three setups compared: an EU assistant, self-hosted, or an EU-hosted data layer.
- How IT teams audit what data an AI model queriedLog the tool calls, not the chat: record who asked, which agent, the exact query and the data version for every AI question. What to log, how to read it, CSV export.
- Stripe MCP for MRR: ask Claude, ChatGPT or Cursor your exact MRRGet the exact MRR from Stripe in Claude, ChatGPT or Cursor: Stripe's MCP server compared, a worked example of 14 subscriptions, the status rule that changes the number, and the setup with a read-only restricted key.
- Pipeline coverage, win rate and sales velocity: formulas and a worked HubSpot exampleHow to calculate pipeline coverage, win rate, sales cycle and sales velocity on 24 real-looking HubSpot deals, with the Excel and Google Sheets formulas, three mistakes that flatter a pipeline, and asking an AI agent the same questions.
- How to add a remote MCP server to any AI clientWhere the MCP server URL goes in Claude, Claude Code, ChatGPT, Cursor, Codex, OpenCode, VS Code, Antigravity, Windsurf and Gemini CLI, with sign-in, checks and fixes.
- Claude MCP: add a remote MCP server as a custom connectorAdd any remote MCP server to Claude web, desktop and mobile as a custom connector: steps, sign-in options, Team setup and fixes.
- Claude Code MCP servers: claude mcp add, .mcp.json and remote setupAdd an MCP server to Claude Code: claude mcp add for remote and local servers, add-json, scopes, the .mcp.json file, /mcp sign-in, claude mcp serve and fixes.
- Cursor MCP: add a remote MCP server to mcp.jsonAdd a remote MCP server to Cursor: mcp.json locations, OAuth and header sign-in, how to check the tools loaded and read MCP Logs.
- Codex MCP config: add an MCP server with codex mcp add or config.tomlCodex MCP config in one place: codex mcp add and codex mcp login, the config.toml entry for remote servers, tokens, timeouts, tool filters and fixes.
- OpenCode MCP: add a remote MCP server with OAuthAdd a remote MCP server to OpenCode: opencode.json config, automatic OAuth, opencode mcp list and debug, and per-agent tool limits.
- VS Code MCP: add a remote MCP server for GitHub CopilotAdd a remote MCP server to VS Code for Copilot agent mode: MCP: Add Server, the two config formats, sign-in, Configure Tools and fixes.
- Antigravity MCP setup: add a remote MCP server to Google AntigravityHow to add an MCP server to Google Antigravity: where mcp_config.json lives, the serverUrl format, OAuth sign-in, header tokens and fixes for common errors.
Automations and apps
REST for n8n, Make and your own code.
- CSV or Excel to API: a REST API with filters and totalsTurn a CSV or Excel (.xlsx) file into a read-only REST API: upload it in the app or with curl, then query JSON with filters, sorting and totals. API keys, versioned results, no server to run.
- Query a large Google Sheet from an n8n AI agentGive an n8n AI Agent a tool that filters and aggregates a Google Sheet server-side, instead of loading every row into the workflow.
- Use Google Sheets as a read-only API with filters and aggregatesQuery a Google Sheet over REST with filters, group-by and totals, kept in sync with the sheet.
- Make: filter and total a big Google Sheet with one HTTP moduleGet filtered rows, group-bys and sums from a large Google Sheet in a Make scenario with one HTTP request, instead of Search Rows and aggregators.
- Zapier: sum and filter a big Google Sheet in a ZapZapier's Sheets lookups return rows, not totals. Get sums, counts and group-bys from a large sheet with one Webhooks by Zapier step.
Comparisons
- csv-api alternatives: datatomcp vs SheetDB, Sheet Best and a DIY MCP serverFree tiers, MCP support, private sheets and sync, side by side.
- Google Sheets API alternatives: SheetDB, Sheet Best, Sheety, Stein and datatomcpFree tiers, prices, writes, server-side totals and MCP support.
- Google's Sheets MCP server vs datatomcpSetup, tools, writes, totals and teams: which one your agents need.