The UK government spent a record £8.7bn in interest on repaying its debts last month, official figures show.
The figure was more than three times as much as the £2.7bn in interest payments seen in June 2020.
The reason was a surge in inflation, which raised the value of index-linked government bonds.
Overall borrowing - the difference between spending and tax income - was £22.8bn, which was £5.5bn lower than June last year.
However, the figure was the second-highest for June since records began.
Borrowing has been hitting record levels, with billions being spent on measures such as furlough payments.
But the cost of servicing all that borrowing has been rising too. Government gilts, for instance, are uprated in line with Retail Price Index inflation, which is higher than the headline consumer inflation rate.
However, analysts stressed that despite the record payment, debt servicing costs as a share of GDP remain low by historic standards.
Ruth Gregory, senior UK economist at Capital Economics, said: "While debt servicing costs will stay higher than the [Office for Budget Responsibility] expects over the next few years, the public finances should reap the benefits of a fuller recovery in GDP than the OBR expects, meaning that the deficit will still fall faster."
Wartime debt level
The huge amount of borrowing over the past year has now pushed government debt up to more than £2.2 trillion, or about 99.7% of GDP - a rate not seen since the early 1960s.
The Institute for Fiscal Studies (IFS) warned that the lower-than-expected borrowing seen in recent months was likely to prove only temporary, leaving Chancellor Rishi Sunak with "very little room for manoeuvre" in his forthcoming Spending Review.
The Office for National Statistics (ONS) now estimates that the government borrowed a total of £297.7bn in the financial year to March.
That was 14.2% of the UK's GDP and the highest level since the end of World War Two.
The ONS said the cost of measures to support individuals and businesses during the pandemic meant that day-to-day spending by the government rose by £204.3bn to £942.7bn last year.
In response to the latest figures, the chancellor said he was "proud of the unprecedented package of support we put in place to protect jobs and help thousands of businesses survive the pandemic".
He added: "However, it's also right that we ensure debt remains under control in the medium term, and that's why I made some tough choices at the last Budget to put the public finances on a sustainable path."
According to the IFS, those tough choices will persist, even though the economy is recovering more quickly than expected at the time of the Budget.
"We now forecast that borrowing in 2021-22 could come in some £30bn lower than the £234bn forecast in the March Budget," the IFS said.
"But this near-term improvement in the outlook is not expected to persist.
"Permanent economic damage done by the pandemic and rising debt interest costs mean that, under our forecast, the chancellor has little, if any, additional headroom against his stated medium-term target of current budget balance (borrowing only to invest, not to fund day-to-day spending)."
That would leave Mr Sunak with virtually no additional room for permanent giveaways in this year's Spending Review, the IFS added.
2px presentational grey line
Analysis box by Andy Verity, economics correspondent
How you view the state of the public finances depends on which measure you pick. If you compare the amount of borrowing that the government needed to do in June to plug the gap between its income from taxes and the amount it spent, it's the second-highest on record. But then you remember that records only go back to 1993. Compared to last June, it's down by £5.5bn.
Similarly with the overall debt (simply put, all the borrowings over the years added up). It's risen - to 99.7% of the size of the economy as measured by gross domestic product, its highest on that measure since 1961. But then you look further back and realise public debt was larger than the size of the economy for 40 of the last 100 years.
Given that the pandemic has put the economy on something like a war footing, it's worth noting that after World War Two, it was 2.5 times the size. The reaction of the government then was not to cut spending, but to embark on the biggest expansion of state spending in history. Sixteen years later, in 1961, prosperity was secure, taxes rolled in and both borrowing and debt dropped rapidly.
As a proportion of the economy, it's businesses' debts, rather than government debts, that are now larger - a consequence of the fact that many small and medium-sized businesses have been given no choice but to borrow their way through the pandemic. Arguably it's that debt, rather than the government "debt" (mostly "borrowed" from itself by issuing currency), which needs the most urgent policy attention in the wake of the pandemic.
2px presentational grey line
Ruth Gregory of Capital Economics said the government had borrowed less in June than forecast by the Office for Budget Responsibility, which had expected it to be £25.2bn.
She said higher tax receipts and stronger GDP growth were further signs that the strong economic recovery was starting to feed through into lower government borrowing.
However, she cautioned that higher taxes were still in the offing as Mr Sunak attempts to rebalance the books after the cost of the pandemic.
"We suspect the chancellor will 'bank' any improvement in the deficit rather than scale back the planned tax hikes and spending cuts set to hit the economy. At least by 2022-23, the economy should be strong enough to cope with it," she said.