When you charge out mileage to your customers on a sales invoice, that income becomes part of your turnover and will be included in the income section of your P&L.
Separate from that you need to somehow record the mileage as an expense so that it shows in the outgoings section of your P&L to (fully or partially) offset the additional income. The amounts need not be the same so it’s not necessarily as simple as adding up all the sales invoice mileage lines and declaring the same amount as an expense, e.g. even though the mileage rate you can claim against profits drops after the first 10,000 miles, you might choose to charge out the full 45p/m to all customers.
If you know you’re doing less than 10,000 total business miles in the year and you are charging out exactly the same 45p/mile as you’re intending to claim back, then the simplest way to tackle it would be to make a new nominal code in the sales section specifically for mileage charges and assign all the mileage lines in your sales invoices to that new code instead of the standard general sales. This would split out the mileage charges from the rest of your sales income on the year end P&L, and then you could journal the same amount credit drawings and debit “travelling” at your year end. This would show the mileage charged out as income and then the same amount claimed as an expense, cancelling it out on the bottom line.
You could also try creating a sales inventory item for mileage, set at the per-mile rate you want to charge out.
Then on each sales invoice the actual number of miles you’re charging goes into the quantity field. At year end I believe there is a report that will tell you how many of each inventory item you have “used” (if there isn’t a dedicated report it’s a fairly simple Excel task to pull the data together from the Sales_Invoice_Items.csv
of an account backup), giving you the data you need to create the expense journal. This would work nicely even if the amount you’re charging out does not match the amount you can claim, since all you care about at year end is the total quantity.