tally-prime-mcp
Tally Prime MCP Server (Read & Write)
An MCP server that lets Claude read, add, modify and delete data in TallyPrime over Tally's XML port. It covers vouchers, item invoices, stock journals, ledgers, stock items, groups, stock groups, godowns, units and cost centres.
Before every change it backs up the company data folder to Desktop\Tally Backups.
Changing an opening balance or opening stock always asks you first.
⬇ Download the latest release (tally-prime-mcp-1.1.0.mcpb, one-click install for Claude Desktop)
⚠️ This tool writes to your books of account. Test it on a copy of your company first, keep backups switched on, and review what Claude proposes before approving deletes or opening-balance changes. Provided as-is under the MIT License.
1. Set up TallyPrime
Open TallyPrime and load the company.
Press F1 (Help) → Settings → Connectivity.
TallyPrime acts as =
Server(orBoth)Note the Port number (default is
9000).
Keep Tally open whenever you want Claude to use it.
Related MCP server: TallyMind MCP
2. Install in Claude Desktop (easiest, nothing else needed)
Install the Claude Desktop app and sign in.
Download
tally-prime-mcp-1.1.0.mcpbfrom the Releases page.Double-click it, then click Install.
In the extension's settings:
Setting | Default | Meaning |
Tally host |
| Host or IP of the PC running TallyPrime |
Tally port |
| Change this to the port from step 1 (usually |
Read-only mode | off | Blocks every write tool |
Backup before every change | on | Copies the company data folder before each create/alter/delete |
Backup folder |
| Where backups go |
Backups to keep per company | 30 | Older automatic backups are removed (0 = keep all; each is about the size of the company folder) |
Start a new chat and ask: "Check Tally status". It should answer "TallyPrime Server is Running" and list your company.
3. Claude Code or another MCP client (optional)
Needs Node.js 18 or newer.
git clone https://github.com/gargcamanish-tech/tally-prime-mcp.git
cd tally-prime-mcp
npm installClaude Code (change the path and port):
claude mcp add --scope user tally-write -e TALLY_PORT=9000 -- node "C:\path\to\tally-prime-mcp\src\index.js"Other clients, add to their MCP config:
"tally-write": {
"command": "node",
"args": ["C:\\path\\to\\tally-prime-mcp\\src\\index.js"],
"env": { "TALLY_PORT": "9000" }
}Environment variables: TALLY_HOST, TALLY_PORT, TALLY_COMPANY, TALLY_READONLY=true, TALLY_AUTO_BACKUP=false,
TALLY_BACKUP_DIR, TALLY_BACKUP_KEEP, TALLY_TIMEOUT_MS (default 180000).
Tools (21)
Area | Tools |
Status & backups |
|
Read |
|
Vouchers |
|
Ledgers |
|
Stock items |
|
Other masters |
|
Advanced |
|
Safety rules built in
Backup first: each write copies the company folder (path read from Tally) to
Desktop\Tally Backups\<company> <date time> <tool>and checks every file was copied. If the backup fails, the change is not made.Opening balance / opening stock: changing a ledger's opening balance, or a stock item's opening quantity, rate, value or godown, takes two steps. The first call writes nothing and returns the current vs new figures; Claude must show you and get your yes. Only then is it repeated with
confirm_opening_change: true.Deletes need
confirm: true. Every write tool also supportsdry_run: trueto preview the XML.Alter changes only the fields you name; everything else is kept: GST and bank details, addresses, bill references.
Read-only mode (
TALLY_READONLY=true) blocks all writes.
Restoring a backup
Close TallyPrime, then copy the numbered folder (e.g. 021047) from inside the backup over the company's data folder
(tally_status shows the path). Reopen Tally.
Examples you can ask Claude
"Record a payment of ₹12,500 from HDFC Bank to Rent on 1 Oct 2025, narration 'October rent'."
"Make a sales invoice to S P Enterprises: 1200 KG SUGAR-17011490-5% @ 42.05, SALES RD, CGST and SGST 2.5% each."
"Change the quantity in invoice A908 to 1000 KG and recompute the taxes."
"Transfer 50 KG sugar from Main Location to Godown 2 on 1 Oct 2025."
"Change the GST rate of SUGAR-17011490-5% to 12% and the HSN to 17019990."
"Create godown 'Shop' and stock group 'Sweeteners'; move the sugar item into it."
Good to know
Educational (unlicensed) TallyPrime only accepts entry dates on the 1st, 2nd and 31st. Other dates fail with "Voucher date is missing".
GST amounts are not calculated by Tally on import; pass the CGST/SGST/IGST ledger lines (Claude can compute them).
Altering or deleting a voucher needs a voucher number that is unique on that date.
list_voucherstakes about 5 s per month of data; financial years are assumed to start in April.
Verified on TallyPrime 6.1
Tested on a live GST trading company; all test objects were removed afterwards.
test/e2e.mjs runs 36 checks through the MCP protocol, and all pass:
ledger create, rename and partial alter (address and GSTIN kept);
opening-balance confirmation;
units, stock groups, godowns and groups;
stock item create, rename, GST/HSN change and opening-stock confirmation (10 → 20);
journal, GST item invoice with bill reference, and stock journal godown transfer: each created, altered and deleted;
closing stock correct;
an automatic backup before every write;
every master type deleted, with Tally still running.
Things learned about this Tally version
A voucher is identified by date + voucher number + type. Matching by GUID/REMOTEID silently creates a duplicate, so alter/delete refuse vouchers with no number, or with a number repeated on the same date.
Alter must send the whole voucher, so the server fetches it, changes only what was asked, and sends it back.
Names use
LANGUAGENAME.LIST. The older top-levelNAME.LISTrename, followed by a delete, crashed Tally (Memory Access Violation). The current method was retested several times without a crash.Opening stock lives in the item's godown batch allocation; the item-level figures alone are ignored on alter.
Development
npm install
TALLY_PORT=9000 TALLY_BACKUP_DIR=<temp folder> npm run e2e # creates, alters and deletes test entries
npx @anthropic-ai/mcpb pack . tally-prime-mcp.mcpbThe e2e test expects ledgers named MISC, ROUND OFF, SALES RD, CGST, SGST and a voucher type SALES GST-RD
in the active company; adjust test/e2e.mjs for your own masters.
License
MIT © 2026 Manish Bansal
This server cannot be deployed
Maintenance
Related MCP Connectors
AI for Tally Prime and Tally ERP 9. Hosted MCP server to ask your accounts in any language.
MCP server unifying ERPs, CRMs, APIs and knowledge base for Claude, ChatGPT and Gemini.
Hosted Amazon Seller and Vendor MCP server for Claude, ChatGPT, Cursor, Codex, Gemini, Copilot.
Augments MCP Server - A comprehensive framework documentation provider for Claude Code
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceThis read-only MCP Server allows you to connect to Tally data from Claude Desktop through CData JDBC Drivers. For full CRUD support, check out our MCP Server for Tally (https://www.cdata.com/drivers/tally/download/mcp).2MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server for TallyPrime ERP that fixes common gaps such as hardcoded localhost, lack of connection diagnostics and dry-run safety, missing GST tools, and session state loss, providing a smoother integration with Claude Desktop.6MIT
- AlicenseAqualityBmaintenanceAn MCP server that lets Claude read from and write to TallyPrime via its built-in XML/HTTP gateway.233ISC
- AlicenseAqualityAmaintenanceA read-only MCP server that connects Claude Desktop to TallyPrime, enabling natural-language auditing and analysis of accounting data directly from the local Tally installation.3919 npmMIT