Turkish companies are struggling to get off the hamster wheel of debt as foreign borrowings run near record highs. The reason: a plunge in the lira that has driven up the cost of their obligations in dollars and euros.

Banks are being left to carry the burden amid a surge in demand from some of the country’s industrial giants to restructure their liabilities — on top of a jump in bad loans. Lenders are also pulling back on providing new credit as the financial system comes under increasing pressure from the recession and an inflation rate of almost 20 percent.

While the lira has recovered from the all-time low it hit in August, the currency is still down by a third against the dollar since the beginning of 2018. The result is that Turkey Inc.’s debt amounts to 40 percent of gross domestic product, exceeding ratios in Eastern Europe’s 10 biggest emerging markets and that of South Africa, which together averaged 22 percent, said data compiled by Bloomberg.

“The key question for Turkish banks is how much further bad debts will deteriorate in the face of deteriorating growth and political uncertainty,” said Tomasz Noetzel, a banking analyst at Bloomberg Intelligence.

Having to rearrange borrowings is adding insult to injury for lenders that have seen their valuations more than halve over the past three years. Efforts by President Recep Tayyip Erdogan’s administration to prop up growth by stoking a credit binge — and leaning on banks to lend at rates barely above inflation — are biting borrowers and lenders alike. The leader on Monday intensified his push for a rerun of last month’s election in Turkey’s biggest city, Istanbul, fueling concerns that an authoritarian streak in government is deepening.

The buffer banks have against any shocks looks “dangerously thin,” Noetzel said. NPLs have swelled about 13 percent this year to $19.3 billion, which means a deeper-than-anticipated economic contraction or renewed pressure on the lira could erode the estimated $27 billion in pre-provision operating-profit cushion the lenders have, he said.

Renewable energy company Bereket Enerji Uretim was the latest firm to ask banks to reorganize $5 billion of loans. That means Turkey’s largest companies have either completed or sought at least $28 billion of restructurings, up from $18 billion a year ago, Bloomberg said.

More than half of the liabilities of Turkish companies is to banks based in the country, more than double the ratio in 2008, central bank data showed. Nonperforming loans as a percentage of total credit rose to 4.11 percent in February from 2.95 percent at the beginning of 2018, said the banking regulator, which predicted the ratio could climb to 6 percent this year. The energy industry alone has more than $51 billion in outstanding debt.

All of Turkey’s large infrastructure projects, including Istanbul’s $11 billion new airport, are financed through foreign-currency loans taken out mainly with local lenders. Their ability to repay is hindered because most of their income is in lira.