Japanese banks are in a bind — again.

Sitting on record levels of excess cash, lenders are turning to riskier investments that need complex foreign exchange hedges, such as U.S. Treasuries, to make a return on deposits that ballooned during the pandemic. Many will be seeking to avoid past mistakes.

The surplus, calculated by subtracting bank loans from deposits, stands at ¥323 trillion, Bank of Japan data show. Deposits at the nation’s top three banks alone grew by ¥41 trillion in the year ending in March, with Mitsubishi UFJ Financial Group Inc. accounting for more than half.