Interest income on securities increased $1.2 million, or 78.4%, to $2.7 million for the nine months ended September 30, 2022 from $1.5 million for the nine months ended September 30, 2021 due to a $86.2 million increase in the average balance of securities to $168.1 million for the nine months ended September 30, 2022 from $81.9 million for the nine months ended September 30, 2021, reflecting the purchase of investments with excess liquidity. The increase was offset by a 32 basis point decrease in the average yield from 2.46% for the nine months ended September 30, 2021 to 2.14% for the nine months ended September 30, 2022.
Interest expense on interest-bearing deposits decreased $430,000, or 12.8%, to $2.9 million for the nine months ended September 30, 2022 from $3.4 million for the nine months ended September 30, 2021. The decrease was due primarily to an 18 basis point decrease in the average cost of interest-bearing deposits to 0.67% for the nine months ended September 30, 2022 from 0.85% for the nine months ended September 30, 2021. The decrease in the average cost of deposits was due to a higher average balance of core deposits, offset by a decrease in the average balance and average cost of certificates of deposit. This decrease was offset by a $50.6 million increase in the average balance of deposits to $581.0 million for the nine months ended September 30, 2022 from $530.3 million for the nine months ended September 30, 2021, primarily due to a $47.4 million increase in the average balance of NOW and money market accounts from $99.3 million for the nine months ended September 30, 2021 to $146.7 million for the nine months ended September 30, 2022.
Interest expense on Federal Home Loan Bank borrowings increased $226,000, or 19.2%, from $1.2 million for the nine months ended September 30, 2021 to $1.4 million for the nine months ended September 30, 2022. The increase was due to an increase in the average cost of borrowings of 37 basis points to 1.92% for the nine months ended September 30, 2022 from 1.55% for the nine months ended September 30, 2021 due to the higher new borrowing rates.
The increase was offset by a decrease in the average balance of borrowings of $3.7 million to $97.6 million for the nine months ended September 30, 2022 from $101.2 million for the nine months ended September 30, 2021.
Net interest income increased $2.6 million, or 18.1%, to $17.0 million for the nine months ended September 30, 2022 from $14.4 million for the nine months ended September 30, 2021. The increase reflected a 30 basis point increase in the net interest rate spread to 2.63% for the nine months ended September 30, 2022 from 2.33% for the nine months ended September 30, 2021. The net interest margin increased 28 basis points to 2.78% for the nine months ended September 30, 2022 from 2.50% for the nine months ended September 30, 2021.
We recorded a $275,000 provision for loan losses the nine months ended September 30, 2022 compared to a $88,000 credit for the nine months ended September 30, 2021. Higher balances in residential and construction loans were the reason for the provision for the nine months ended September 30, 2022. The Bank continues to have a low level of delinquent and non-accrual loans in the portfolio, as well as no charge-offs.
Non-interest income decreased by $2.4 million, or 73.1%, to $868,000 for the nine months ended September 30, 2022 from $3.2 million for the nine months ended September 30, 2021. For the nine months ended September 30, 2021, there was a $1.9 million bargain purchase gain recognized in the Gibraltar Bank acquisition in 2021. Gain on sale of loans decreased $560,000 or 86.6% to $87,000 for the nine months ended September 30, 2022 from $647,000 for the nine months ended September 30, 2021. Bank-owned life insurance income increased $119,000, or 30.3%, to $511,000 for the nine months ended September 30, 2022 from $392,000 for the nine months ended September 30, 2021 due to a $5.0 million purchase of bank-owned life insurance during the nine months ended September 30, 2022.
For the nine months ended September 30, 2022, non-interest expense decreased $12,000, or 0.1%, to $10.8 million, over the comparable 2021 period. Salaries and employee benefits increased $713,000, or 12.7%, due to stock compensation plan implemented in September 2021 and due to more employees due to the acquisition and the addition of a sixth branch office. Data processing expense increased $143,000, or 18.3%, due to higher data processing expense associated with a larger company. Advertising expense increased $188,000 due to additional promotions for branch locations and new promotions for loan and deposit products. Professional fees decreased $137,000, or 23.0%, due to lower consulting expense. Merger fees and core conversion costs were $1.1 million in 2021. The increase in equipment and occupancy expenses of $134,000, or 14.9%, was mainly due to the additional branch locations.