Fixing the “Date Not in Fiscal Year” Error in ERPNext
When creating accounting transactions in ERPNext, the system validates whether dates such as the Posting Date or Transaction Date fall within the selected Fiscal Year.
If the transaction date lies outside the selected Fiscal Year, ERPNext prevents the document from being saved and displays the following validation error:
Date DD-MM-YYYY not in fiscal year
This commonly occurs after creating a new Fiscal Year but forgetting to make it the default Fiscal Year for the company.
Most “Date not in Fiscal Year” errors occur because the new Fiscal Year exists but has not been configured as the default Fiscal Year.
1. Why This Error Appears
ERPNext validates every accounting transaction against the Fiscal Year assigned to it.
You may encounter this error when:
- A new financial year has started.
- The transaction date belongs to a different Fiscal Year.
- The new Fiscal Year has been created but not set as default.
- Global Defaults still point to the previous Fiscal Year.
2. Create a New Fiscal Year
Before recording transactions for a new accounting period, create the corresponding Fiscal Year.
Navigate to:
Accounting → Accounting Masters → Fiscal Year
Then:
- Click New.
- Enter the Fiscal Year name.
- Select the Start Date.
- Select the End Date.
- Save the document.
Only users with the System Manager role can create new Fiscal Years.
3. Set the Fiscal Year as Default
After saving the Fiscal Year:
- Open the Fiscal Year document.
- Click Set as Default.
- Save the changes.
Setting the Fiscal Year as default ensures that new accounting transactions automatically use the correct financial period.
4. Verify Global Defaults
The default Fiscal Year is also stored in Global Defaults.
Navigate to:
Settings → Core → Global Defaults
Verify that:
- The Default Fiscal Year matches the current accounting year.
- The configuration has been saved.
If necessary:
- Select the correct Fiscal Year.
- Save the document.
- Reload ERPNext.
Refreshing ERPNext after updating Global Defaults ensures the latest Fiscal Year settings are applied throughout the system.
5. Manually Selecting a Fiscal Year
Even after setting a default Fiscal Year, users can manually choose another Fiscal Year for individual transactions.
To do this:
- Open the transaction.
- Expand the More Info section.
- Select the appropriate Fiscal Year.
This is useful when recording historical transactions or backdated entries.
6. Troubleshooting
If the error still appears:
- Confirm that the transaction date falls within the selected Fiscal Year.
- Verify the Fiscal Year Start and End Dates.
- Ensure the correct Fiscal Year is marked as Default.
- Check Global Defaults for the active Fiscal Year.
- Reload ERPNext after making configuration changes.
7. Best Practices
- Create the next Fiscal Year before the new accounting period begins.
- Immediately set the new Fiscal Year as the default.
- Review Global Defaults whenever a new Fiscal Year is created.
- Reload ERPNext after changing Fiscal Year settings.
- Use manual Fiscal Year selection only when entering historical transactions.