Bank of America Corp. traders reported their best third-quarter results in more than a decade while net interest income topped analysts’ estimates as the lender continues to reap the benefits of Federal Reserve rate hikes and volatile markets.

The firm’s fixed-income and equity traders trumped expectations, with stock-trading revenue up 10% to a record $1.7 billion. The quarter saw dramatic market swings, as the Fed’s push to quell inflation with higher interest rates helped traders. The windfall from trading helped Bank of America’s net income surge 10% to $7.8 billion, or 90 cents a share, topping analysts’ 81-cent estimate.

The second-largest US bank also said that NII, a key source of revenue for the bank, rose 4.5% to $14.4 billion in the quarter. Analysts had expected a 2.5% increase for NII, the revenue collected from loan payments minus what depositors are paid.

“We added clients and accounts across all lines of business,” Chief Executive Officer Brian Moynihan said in a statement Tuesday. “We did this in a healthy but slowing economy that saw US consumer spending still ahead of last year but continuing to slow.”

The results offer another look at how US consumers and businesses are faring as the Federal Reserve leaves borrowing costs higher for longer than economists had predicted. Last week, JPMorgan Chase & Co., Wells Fargo & Co. and Citigroup Inc. beat analysts’ expectations for net interest income and raised their forecasts for the remainder of the year. Bank of America maintained its guidance, with fourth quarter NII projected to be around $14 billion, executives said on a conference call with analysts.

Shares of Charlotte, North Carolina-based Bank of America were little changed at $26.99 at 9:55 a.m. in New York. They’ve slumped 19% this year, less than the 23% decline for the KBW Bank Index.

Bank of America’s non-interest expenses rose 3.5% from a year earlier to $15.8 billion. Costs have been a focal point for investors, with persistent inflation putting pressure on spending and spurring wage growth. Analysts had expected a 3.3% increase.

The firm’s revenue growth continued to outpace the increase in expenses. That’s due in large part to strength in the markets business, where stock traders posted a record third quarter driven by financing activity.

“As our clients have grown, we can profitably deploy more resources in that business,” Chief Financial Officer Alastair Borthwick said on a conference call with reporters. The markets unit, led by Jim DeMare, has taken those resources and deployed them to “capture more market share over time.”

The company’s other Wall Street unit, its investment bank, also beat analyst expectations across the board, notching $1.25 billion of total fees excluding self-led deals. Fees for advising on mergers and acquisitions rose 3.7%, and revenue from equity issuance jumped 49%, while revenue from debt issuance fell 7.5%, better than the 10% drop analysts had predicted.

On the lending side, the firm’s loan balances rose to $1.049 trillion at the end of the third quarter, up 1.6% from a year earlier, less than analysts’ estimates of $1.053 trillion. Lending has been a key focus for investors, with government-stimulus payments cutting into borrowing by companies and consumers during the pandemic, and rising interest rates now making loans costlier.

Bond losses in the bank’s held-to-maturity portfolio widened to $131 billion in the third quarter, compared to $116 billion for same period a year ago. Such losses aren’t recognized in earnings because the bank plans to hold the bonds until they are paid off.

This article was provided by Bloomberg News.