1. Your BAI2 file
Usually a .bai, .bai2, .txt or .csv file from your bank's prior-day or current-day reporting: lines beginning 01, 02, 03, 16, 88, 49, 98 and 99 and ending in a slash.
Choose a file or paste the text, then click Read and check.
Result
Accounts
| Line | Account | As of | Ccy | Opening | Closing | Items | Credits | Debits |
|---|
Transactions
| Line | Account | Type | Amount | Bank ref | Customer ref | Text |
|---|
Rebuild the trailers
The model, and what it leaves out
- Records: 01 file header, 02 group header (statement date), 03 account with balance and summary entries, 16 transaction, 88 continuation of the record before it, 49 account trailer, 98 group trailer, 99 file trailer. Every record ends with a slash.
- Amounts are whole cents with no decimal point. A 16 record is a credit for type codes 100 to 399 and a debit for 400 to 699; codes 010 to 099 are balances. Common codes have names; others show their range.
- Control totals: the 49 total is accepted if it equals any of four sums (transactions; transactions plus summary lines; plus balances; balances plus transactions) because banks differ. 98 is the sum of the 49 totals and 99 the sum of the 98 totals. Record counts include 88 lines.
- Roll-forward: opening ledger (010) plus credits minus debits should equal closing ledger (015). A gap is a warning, not an error: pending items and bank adjustments can explain it.
- Rebuild rewrites 49, 98 and 99 only, using the convention the file already follows. It never edits a transaction or a balance, and it joins any 88 lines onto their record.
- Not checked: bank-specific extra fields, lockbox and BAI1 or BTRS layouts, loan and international variants beyond reading them, your books, and anything that needs the bank's own records.
Common questions
How do I read a BAI2 file?
Paste it or drop it onto this page. It splits the comma-separated records, joins 88 continuation lines, and shows each account with its opening and closing balances and a table of transactions with type, amount, bank reference, customer reference and text. You can download the transactions as a CSV for Excel or your accounting system.
What is a BAI2 file?
BAI2 is the cash-management format banks use to send balance and transaction reporting to companies: record 01 is the file header, 02 a group of accounts as of a date, 03 an account with its balances, 16 a transaction, 88 a continuation of the line before, 49 the account trailer, 98 the group trailer and 99 the file trailer. Amounts are whole cents with no decimal point.
Why does my accounting system reject the BAI2 file?
The usual causes are control totals that no longer match after the file was edited or truncated, a record count that does not include 88 continuation lines, a missing closing slash, an amount written with a decimal point, or a missing 99 trailer from a partly downloaded file. This tool checks each of them and gives the line.
What does the account control total in the 49 record include?
Banks differ. Some sum only the 16 transaction amounts, some also add the summary lines in the 03 record such as total credits, and some add the balances too. This tool accepts any of those four sums, says which one the file follows, and only reports an error when none of them matches.
Can this tool fix my BAI2 file?
It can rebuild the 49, 98 and 99 trailers, the totals and record counts, from the records above them. It never changes a transaction or a balance, because a wrong amount is a data question for the bank, not a typo. If the trailers were right and the transactions were edited, the rebuild would hide the edit, so look at the findings first.
Is it safe to put a bank statement file into a web page?
The page runs in your browser, the file is read locally and nothing is uploaded; a test in the code asserts there are no network calls. Account numbers are masked to their last four digits in the report and in the exports. Your own policies still decide whether you may open a bank file in a browser.
What does this not check?
Whether your bank's variant adds fields, lockbox and other BAI formats, the BTRS or BAI1 layouts, whether the closing balance is right for your books, and anything that needs the bank's own records. A clean result is not a promise that a system will import the file.