Typically your accountant would deal with the accounting entries for your R&D tax claimm but it useful to understand the mechanics so that you can see how it fits into the overall build up of your financial statements.
Note: Xero has an odd way of recognising corporation tax. It recognises it within 'Administrative Expenses', whereas it should be posted below net profit.
I have seen at least one company have to restate their accounts as they 'accidentally' published their previous accounts with the corporation tax entry tucked away in Admin expenses!
In summary, the R&D tax credits are recognised both in your Income Statement (Profit & Loss account) and Balance sheet.
Income statement (profit & loss account)
Given that the benefit either reduces corporation tax otherwise paid/payable OR results in a tax credit rebate from HMRC, this is recognised as income (or a "credit" in accounting-speak!)in your Income Statement.
It will be credited to the corporation tax line in your accounts in the current year if it relates to that year, or to the 'prior year' if it has been applied to prior periods.
It is often good practice to ignore the benefit of the R&D tax credit for the current year accounts and to apply the benefit in the following year (as a prior year entry to corporation tax).
This is a more prudent approach as the claim will not have been agreed at the time that the accounts are being prepared - so the benefit could be overstated should HMRC challenge or deny the claim.
Note that the SME R&D benefit is posted "below the line" as it falls below net profit (note that the Large company (RDEC) treatment is different...).
The corresponding entry is to 'corporation tax recoverable' or a reduction in the corporation tax creditor in the balance sheet.
Hopefully, that wasn't too yawnsome!