Understanding Debit and Credit
Debits and credits are the two sides of every accounting entry. They do not mean good and bad, or money in and money out. They describe how an amount changes an account. In ERPNext, the total debit and total credit for every accounting transaction must be equal.
You can use ERPNext without entering most debits and credits manually. Understanding them still helps you review the Accounting Ledger, configure accounts correctly, and diagnose unexpected balances.
Start with the accounting equation
The balance sheet is built on:
Assets = Liabilities + Equity
Income increases profit and therefore increases equity. Expenses reduce profit and therefore reduce equity. This gives the normal behavior of the five account classes:
| Account class | What it represents | Increase with | Decrease with | Common examples |
|---|---|---|---|---|
| Asset | Resources the company owns or controls | Debit | Credit | Cash, bank, receivables, inventory, equipment |
| Liability | Amounts the company owes | Credit | Debit | Payables, loans, tax payable |
| Equity | Owners' residual interest | Credit | Debit | Capital, retained earnings |
| Income | Value earned during a period | Credit | Debit | Sales, service income |
| Expense | Value consumed during a period | Debit | Credit | Rent, salaries, cost of goods sold |
A useful memory aid is: assets and expenses normally increase on the debit side; liabilities, equity, and income normally increase on the credit side.
The word normally matters. An account can contain entries on both sides. A Customer payment credits receivables because it reduces an asset. A sales return debits sales because it reduces income.
Debit and credit are not payment directions
Consider three events:
- A Customer pays an invoice. Bank is debited because the bank asset increases. Receivables are credited because the amount owed by the Customer decreases.
- You pay a Supplier. Payables are debited because the liability decreases. Bank is credited because the bank asset decreases.
- You buy a laptop for cash. Equipment is debited because an asset increases. Bank is credited because another asset decreases.
The same bank account can therefore be debited or credited depending on whether its balance increases or decreases.
How common ERPNext transactions balance
The examples use simplified values and omit rounding. Account names in your Company may differ.
Credit sale
Nova Electronics Trading issues a Sales Invoice for USD 1,000 plus USD 80 tax and will collect payment later.
| Account | Debit | Credit |
|---|---|---|
| Accounts Receivable | 1,080 | |
| Sales | 1,000 | |
| Tax Payable | 80 | |
| Total | 1,080 | 1,080 |
Receivables increase because the Customer owes more. Income and tax liability also increase. A submitted Sales Invoice creates these entries automatically from its items, taxes, and configured accounts.
Receive the Customer payment
The Customer pays USD 1,080.
| Account | Debit | Credit |
|---|---|---|
| Bank | 1,080 | |
| Accounts Receivable | 1,080 | |
| Total | 1,080 | 1,080 |
Cash at bank increases and the Customer's debt decreases. A Payment Entry also links this amount to the invoice so its outstanding balance becomes zero.
Credit purchase
Nova receives a Supplier invoice for USD 600 of office equipment.
| Account | Debit | Credit |
|---|---|---|
| Office Equipment | 600 | |
| Accounts Payable | 600 | |
| Total | 600 | 600 |
The equipment asset and Supplier liability both increase. If the purchase were an operating expense, the debit would go to an expense account instead.
Pay the Supplier
| Account | Debit | Credit |
|---|---|---|
| Accounts Payable | 600 | |
| Bank | 600 | |
| Total | 600 | 600 |
Both the liability and the bank asset decrease.
Deliver stock to a Customer
Suppose a laptop sold for USD 1,000 has a valuation cost of USD 700. With perpetual inventory, the delivery records the cost separately from the sale:
| Account | Debit | Credit |
|---|---|---|
| Cost of Goods Sold | 700 | |
| Stock Asset | 700 | |
| Total | 700 | 700 |
Cost of goods sold increases as an expense; inventory decreases as an asset. This entry can come from a Delivery Note or a stock-updating Sales Invoice.
Receive stock before the Supplier invoice
When goods are received before billing:
| Account | Debit | Credit |
|---|---|---|
| Stock Asset | 700 | |
| Stock Received But Not Billed | 700 |
The Purchase Receipt records the inventory and a temporary liability. The later Purchase Invoice debits Stock Received But Not Billed and credits Accounts Payable. This clears the receipt accrual and establishes the Supplier balance.
Record an expense paid immediately
Nova pays USD 120 for internet service.
| Account | Debit | Credit |
|---|---|---|
| Internet Expense | 120 | |
| Bank | 120 |
An expense increases and the bank asset decreases. This can be recorded through a Purchase Invoice followed by payment, or an appropriate payment or journal workflow based on the required controls and evidence.
Record depreciation
| Account | Debit | Credit |
|---|---|---|
| Depreciation Expense | 100 | |
| Accumulated Depreciation | 100 |
Depreciation expense increases. Accumulated depreciation is a contra-asset account with a normal credit balance, so it reduces the net book value of the Asset without changing its original cost account.
Contra accounts and unusual balances
A contra account offsets another account while remaining separately visible. Common examples include accumulated depreciation, sales returns, purchase returns, and allowances.
An account can also show an unexpected balance without being invalid:
- A Customer receivable with a credit balance may represent an advance or overpayment.
- A Supplier payable with a debit balance may represent an advance paid.
- A bank account with a credit balance may represent an overdraft.
- Income may be debited by a Credit Note or correction.
Investigate the source vouchers and business meaning before deciding that the sign is wrong.
How parties and accounts work together
ERPNext usually uses a shared receivable account for many Customers and a shared payable account for many Suppliers. The Party Type and Party on each ledger entry identify whose balance changed.
This is why the Chart of Accounts does not need one ledger account per Customer. The Accounts Receivable and Payable reports combine account postings with party and payment references to show invoice-level outstanding amounts and ageing.
Dimensions do not change debit and credit
A Cost Center, Project, or other Accounting Dimension tags an entry for analysis. It does not replace the account or change whether the amount is a debit or credit.
For example, one rent expense account can be split across Retail, Online Sales, and Administration Cost Centers. The General Ledger remains balanced, while the Profit and Loss Statement can be filtered or grouped for management reporting.
Review entries in ERPNext
After submitting a transaction:
- Open the source document.
- Select View > Accounting Ledger.
- Confirm the debit and credit totals are equal.
- Check that each account matches the economic event.
- Verify the party on receivable or payable rows.
- Review the Cost Center, Project, Finance Book, and other dimensions where applicable.
- Open the General Ledger to see the entry in account context.
Use the Trial Balance to confirm that total debits and credits remain equal across the selected period. Equality proves mathematical balance, but it does not prove that every account choice is correct.
When to use a Journal Entry
Use a Journal Entry for genuine accounting adjustments such as accruals, provisions, reclassifications, opening balances, and approved write-offs.
Prefer specialized transactions for normal operations:
- Sales Invoice for Customer billing
- Purchase Invoice for Supplier billing
- Payment Entry for receipts, payments, and internal transfers
- Delivery Note, Purchase Receipt, or Stock Entry for inventory movement
- Asset transactions for capitalization, depreciation, sale, and disposal
Specialized documents calculate taxes, update outstanding amounts, preserve operational references, and apply validations that a manual Journal Entry may bypass.
Common mistakes
| Mistake | Better approach |
|---|---|
| Treating debit as money received | Identify the account class, then ask whether that account increased or decreased. |
| Treating credit as a negative amount | Read debit and credit as sides of an entry, not positive and negative signs. |
| Creating one receivable account for every Customer | Use shared receivable accounts and let the Party identify the Customer unless a separate account is required. |
| Fixing an invoice with an unrelated Journal Entry | Correct, return, cancel, or amend the source document where possible so operational and accounting records agree. |
| Checking only that totals balance | Also verify accounts, parties, dates, dimensions, references, taxes, and currencies. |
Frequently asked questions
Why does a bank receipt appear as a debit?
Bank is an asset. Receiving money increases that asset, and an asset increase is a debit.
Why is sales income a credit?
Income increases profit and equity. Income accounts therefore normally increase with credits.
Can I enter a negative debit?
ERPNext usually represents the opposite effect on the other side of the entry. Follow the relevant document's return or reversal workflow rather than forcing negative values.
Does every transaction affect exactly two accounts?
- Double entry requires equal totals, not exactly two rows. An invoice with several taxes, income accounts, discounts, and stock effects can create many GL Entries.