File naming rules under Japan's Electronic Books Preservation Act — examples and common mistakes
Updated 2026-09-14. Based on the National Tax Agency's Electronic Books Preservation Act Q&A [Electronic transactions] (July 2026). "Q" numbers below refer to that Q&A. This page explains requirements of Japanese law.
Key points
- Invoices, receipts and similar data received by email or online must be kept as data. Printing them on paper is not enough (Q30).
- Even without dedicated software, the National Tax Agency explains that the search requirement is met if the file name contains the transaction date, the amount and the counterparty in a consistent order, and you are ready to provide the data when a tax official asks you to download it (Q50).
- Example: an invoice for 110,000 yen from Kasumi Shoten Co., Ltd. dated January 31, 2024 becomes
20240131_(株)霞商店_110000.pdf - The file name alone does not cover every requirement. You also need a measure against tampering, such as setting internal rules and following them (Q19, Q30).
What is required when keeping electronic transaction data
The following are required (Q18). File naming rules relate to the third item.
- Take a measure against tampering: a timestamp, a system that keeps a history of corrections and deletions (or does not allow them), or internal rules for preventing corrections and deletions. The National Tax Agency publishes sample internal rules (reference materials, in Japanese).
- Have a display and a printer so the data can be shown on screen or printed promptly.
- Make the data searchable by the transaction date (or another date), the amount and the counterparty.
- If you use a program you developed yourself, keep a document describing the system.
What the search requirement means
The National Tax Agency lists three search functions (Q48).
- You can search by the transaction date (or another date), the amount and the counterparty
- You can search dates and amounts by range
- You can combine two or more items in one search
If you are ready to respond to a tax official's request to download the data (to show or submit it), items 2 and 3 are not needed. On top of that, if either of the following applies, none of items 1 to 3 are needed (Q48, Q51, Q52).
- Sales in the base period (two years before for individuals, two business years before for corporations) are 50 million yen or less
- You can show or submit printouts of the data sorted by date and by counterparty
Even when the search requirement does not apply, consistent file names save time when you look for a document or hand files to your tax accountant.
File naming examples
National Tax Agency materials show the following patterns. Each puts the date, the counterparty and the amount in the name, in the same order every time.
| Pattern | Example | Source |
|---|---|---|
| date_counterparty_amount | 20210131_(株)霞商店_110000 |
Q19, Q50 |
| date_amount_counterparty | 20240331_110000_(株)霞商店.pdf |
Leaflet "Check how to keep electronic transaction data" (July 2023) |
| A folder per counterparty, with date_amount as the file name | (株)霞商店/20240331_110000.pdf |
Q50 (separating folders by counterparty) |
Adding the document type (invoice, receipt, etc.) or the invoice number makes the content clear at a glance. Even then, keep the three items in the same position in every file name.
What to decide first
| Item | What the National Tax Agency says, and how to decide |
|---|---|
| Western calendar or Japanese era | Either is fine, but mixing them gets in the way of searching, so use one (Q50). |
| Which date to use | Normally the date of the transaction. For a document that records a month of transactions together, you may use the issue or receipt date and the total amount, as long as you do so consistently within the tax period (Q55). |
| Tax included or excluded | Normally match your bookkeeping method (tax-excluded or tax-included accounting), but the amount written on the document is also acceptable (Q57). |
| Documents without an amount | For documents such as unit-price contracts, the amount may be 0 yen or blank. If blank, make sure blank entries can be searched (Q58). |
| Quotations with several amounts | Decide internally which amount to use and do not change the rule during the tax period (Q56). |
| How to write the counterparty | Whether to write 株式会社 in full or shorten it to (株). The National Tax Agency examples use (株). Mixed spellings cause missed search results, so pick one. |
Common mistakes
- Dates are written differently from file to file. If
2024-1-5,20240105andR6.1.5are mixed, sorting by name does not sort by date. With a fixed-widthYYYYMMDD, name order is date order. - The order of the items changes midway. The National Tax Agency describes entering the items in a consistent order (Q50). If several people handle files, write the rule down and share it.
- Commas or 円 are added to some amounts but not others.
110,000and110000are different strings, so searching for one misses the other. The National Tax Agency examples use digits only. - Counterparty names are not consistent. If 株式会社霞商店, (株)霞商店 and カスミ商店 are mixed, a single search cannot find them all.
- A PDF containing several invoices is named as one file. The Q&A describes splitting the PDF by transaction and naming each part. Split it without changing the content (Q54).
- Files are named, but there is no measure against tampering. You need, for example, internal rules that you set and follow (Q19).
- Files are stored all over the place. Storing data in more than one place is allowed, but data scattered without reason that cannot be produced promptly is not (Q32).
- Invoices you sent are not kept. Data you send must be kept as well as data you receive (leaflet "Check how to keep electronic transaction data").
- The file name contains characters that are not allowed. Windows does not allow
\ / : * ? " < > |in file names. If a counterparty name contains any of them, replace them with another character.
How long to keep the data
As with paper documents, the retention period for electronic transaction data is set by the Income Tax Act, the Corporation Tax Act and other tax laws (Q17).
- Corporations: 7 years (10 years for business years with a loss carried forward under a blue return, among other cases)
- Sole proprietors filing a blue return: 7 years for receipts and other documents related to cash and deposit transactions (5 years if business and real estate income two years before was 3 million yen or less); 5 years for invoices, quotations, contracts and other documents
- Sole proprietors filing a white return: 5 years for invoices, receipts and similar documents
- Invoices kept by a consumption tax payer to claim the input tax credit: 7 years, regardless of the above
See the table in Q17 for when the period starts.
Make file names consistent with Dencho Rename
Drop PDFs into Dencho Rename and it reads the date, amount and counterparty from the text, renames every file by the rule you chose, and returns them as a ZIP. You can choose the order, the date format, and whether to shorten 株式会社 to (株). Files are processed only inside your browser and never uploaded.
Sources
- National Tax Agency, Electronic Books Preservation Act Q&A [Electronic transactions] (July 2026, in Japanese)
- National Tax Agency, leaflet "Check how to keep electronic transaction data" (July 2023, in Japanese)
- National Tax Agency, reference materials (sample rules and forms, in Japanese) (sample index book and sample internal rules)