How to Use AI to Read Receipts and Invoices
AI can pull dates, vendors and totals out of messy receipts, but it sometimes misreads a digit. A field schema, three arithmetic checks and a review queue keep errors out of your books.
How to use AI to read receipts and invoices comes down to this: photograph or scan the document, ask a vision-capable model to return fixed fields as structured data, then run arithmetic checks on the result before anything is saved. The model reads the text well. What it occasionally gets wrong is a single digit, a swapped date format, or a total picked from the wrong line. The checks exist to catch exactly those errors.
This guide is for a small business owner or bookkeeper with a pile of paper and PDFs. It covers which fields to ask for, the three checks that matter, what to send to a human, and what to keep for the tax authority.
Step 1: decide the fields before you upload anything
Vague requests produce vague answers. Give the model a fixed list, and tell it what to do when a field is missing. Missing should come back as null, not a guess.
{
"vendor_name": "string",
"document_type": "receipt | invoice | credit_note",
"invoice_number": "string or null",
"issue_date": "YYYY-MM-DD",
"currency": "three-letter code",
"line_items": [
{ "description": "string", "quantity": "number", "unit_price": "number", "amount": "number" }
],
"subtotal": "number or null",
"tax_amount": "number or null",
"total": "number",
"payment_method": "string or null"
}Ask for the dates in one format and say so in the prompt. A receipt that reads 03/04/2026 could be 3 April or 4 March depending on the country, and the model has no way to know unless you tell it where the business operates. If your tools support structured output, use it so the reply always parses. The idea is explained in what is structured output in AI.
Step 2: run three checks on every result
These checks are plain arithmetic, so they cost nothing and need no AI. Run them in code or a spreadsheet formula.
Check | Rule | What it catches |
|---|---|---|
Lines add up | Sum of line item amounts equals the subtotal, within one cent | A misread digit in a line, or a line that was skipped |
Total adds up | Subtotal plus tax equals the total, within one cent | The model grabbing a tip, a balance due or a previous total |
Sanity | Date is not in the future, is within the last few years, and the currency matches the vendor's country | Swapped day and month, a wrong year, a currency symbol read as the wrong code |
A document that passes all three is much more likely to be right. A document that fails any one is flagged, not corrected. Do not let the model quietly fix its own numbers, because that hides the error you wanted to see.
Step 3: decide what goes to a human
Keep the rule simple enough that you will actually follow it.
Auto-accept: all three checks pass, and the amount is under a limit you set, for example what you would shrug off if it were wrong.
Quick review: all checks pass, but the amount is over the limit. A person glances at the image and the extracted total side by side.
Full review: any check fails, the image was blurry or cropped, or a field the books need came back null.
Spot-check a few auto-accepted items each week against the original image. If you find an error that passed the checks, add a new check for that pattern.
What goes wrong with real paperwork
Thermal receipts fade. Photograph them the day you get them, in even light, flat on a table.
Handwritten notes and tips. A handwritten total or tip is the most common source of wrong totals. Route anything with handwriting to review.
Multi-page invoices. Upload all pages together and ask for one result, or the model will treat each page as its own invoice.
Foreign currencies. Extract the amount in the original currency and convert in your accounting tool, not in the prompt.
Duplicates. The same invoice arrives by email and by post. Check vendor, invoice number and total against what you already have before you save.
Keep the original, always
The extracted data is a convenience. The original image or PDF is your evidence. In the UK, GOV.UK says self-employed people must keep their records for at least 5 years after the 31 January submission deadline of the relevant tax year, and other countries have their own rules. Check yours, and store the original next to the extracted record with a stable filename.
Privacy and where this sits in your workflow
Receipts carry names, partial card numbers and addresses. Check what your AI provider does with uploaded files and whether your plan keeps them for training before you send customer invoices. For a wider view of connecting AI to finance tools, read is it safe to connect an AI agent to QuickBooks.
AI reading documents is one part of the larger picture covered in AI for small business. For what it can and cannot replace in bookkeeping, see can AI replace a bookkeeper, and once the data is clean, how to use AI to chase late invoices is a natural next step.
FAQ
Can ChatGPT read a receipt photo?
Models with image input can read most clear receipt photos. Accuracy falls with blur, fading, folds and handwriting, which is why the arithmetic checks matter.
Is AI receipt scanning accurate enough for tax records?
It is accurate enough to save typing, not accurate enough to trust unchecked. Keep the original document and run checks on the extracted numbers.
How do I stop AI from guessing missing fields?
Tell it to return null for anything not visible, and add a rule that null fields send the document to review.
Should I let AI categorize expenses too?
You can, as a suggestion. Have it propose a category from your own chart of accounts and let a person approve until it has been right for a long stretch.
How did this land?
About the author

Developer Advocate
Steve builds something with Swarmz every week and writes up what worked, what broke, and what he'd do differently. Tutorials and hands-on guides are his lane.


