Templates / Telegram AI Expense Tracker: Track Expenses via Bot to Google Sheets

Telegram AI Expense Tracker: Track Expenses via Bot to Google Sheets

Intermediate   Apps: Telegram, OpenAI, Google Sheets  ·  Setup: 15 minutes

Expense tracking apps require separate logins and complex interfaces, making it hard to quickly record purchases. Receipt photos get lost in your phone gallery. This workflow creates a Telegram bot where you can send simple messages like 'Coffee $4.50 at Starbucks' and have AI automatically extract the amount, category, merchant, and timestamp into a Google Sheet for easy analysis.

Download workflow JSON (free) Setup guide

What this workflow does

  1. A Telegram Trigger listens for messages sent to your bot.
  2. An OpenAI node extracts amount, category, and merchant from the message text.
  3. A Code node validates the extracted data and formats it for Sheets.
  4. A Google Sheets node appends the expense to your expense tracking spreadsheet.
  5. The bot sends a confirmation message back to the user.

Setup guide

  1. Import the JSON into n8n (Workflows > Import from File).
  2. Connect Telegram, OpenAI, and Google Sheets in their respective nodes.
  3. Replace REPLACE_WITH_BOT_TOKEN with your Telegram bot token.
  4. Replace REPLACE_WITH_SPREADSHEET with your Google Sheet ID.
  5. Create a Google Sheet with columns: Date, Amount, Category, Merchant, Note.
  6. Set up your Telegram bot webhook to point to this workflow's Telegram Trigger URL.

Want this running 24/7?

Self-host n8n on a cheap VPS and this workflow runs around the clock for less than a coffee a month.

Get an n8n VPS from $5/month

FAQ

What message formats does the AI understand?The AI is trained to recognize various expense formats like 'Dinner $45', 'Gas $30 at Shell', 'Book $15 Amazon', 'Lunch 25 USD'. It extracts amount, merchant, and category. More specific details in the note field.
What if the AI misclassifies an expense?Review your expense sheet regularly. You can correct classifications in the sheet or improve the AI prompt in the OpenAI node with examples of your common expense types for better accuracy.
How secure is sending expense data via Telegram?The message travels from your phone to Telegram's servers, then to your n8n instance. For sensitive expense information, ensure your n8n instance is properly secured with HTTPS and access controls.

Want the workflows this one is a warm-up for?

The Mega Bundle packs both WorkflowForge Pro volumes — 32 production-grade workflows: automations (cart recovery, lead scoring, invoice extraction) and AI agents (support agent, calendar assistant, research agent), each with a setup guide. $39 for both, instant download.

Get the Mega Bundle →

Need it customized for your exact process?

I build custom n8n automations and AI agents professionally: your tools, your edge cases, tested and documented.

Hire me on Fiverr →