We prepare closing entries for the temporary accounts such as the revenue and expense accounts (see earlier Q&A). The closing entries are recorded after the financial statements for the accounting year are prepared. The reason for the closing entries is to ensure that each revenue and expense account will begin the next accounting year with a zero balance.
The closing entries require that a debit be entered into each of the temporary accounts having a credit balance. The debit entered must be exactly the amount of the credit balance prior to the closing entry. The objective is to get the account balance to be zero.
The closing entries also require that a credit be entered into each of the temporary accounts having a debit balance. The credit amount that is entered must be exactly the amount of the debit balance prior to the closing entry.
The net amount of the debits and credits in the closing entries for the income statement accounts is the amount of the income or loss. This net amount will end up in the balance sheet account Retained Earnings (part of stockholders' equity of a corporation) or in the owner's capital account (part of owner's equity in a sole proprietorship). In manual systems, there is often an Income Summary account before the entry into the equity account.
With some accounting software the closing entries are prepared and posted by selecting "closing entries." With other accounting software, formal closing entries are not used. Instead, the user specifies the beginning and ending dates of the information needed.