Interest expense, net increased to $1,700 from $628 for the three months ended June 30, 2023 as compared to the prior year period. Increases in interest expense, net was primarily due to increases in floor plan interest payments, increased borrowings on our credit facility and increased interest rates.
For the three months ended June 30, 2023 the Company recognized a net foreign currency exchange gain of $273, compared to a net loss of $311 for the three months ended June 30, 2022, reflecting foreign currency gains and loss on transactions denominated in a currency other than the local entity’s functional currency.
The provision for income taxes for the three months ended June 30, 2023 and 2022 reflects a combined effective U.S. federal, state and foreign tax rate of 21.4% and 22.1%, respectively. The principal differences between the federal statutory tax rate and the effective tax rate consist primarily of state taxes, domestic tax credits, and tax differences on foreign earnings.
Results of Operations – Six Months Ended June 30, 2023 Compared to Six Months Ended June 30, 2022
Net sales for the six months ended June 30, 2023 increased 39.7% to $582,539 from $417,045 for the comparable period in 2022. The increase in revenue is the result of the realization of price increases and increases in production volume across all our product categories due to supply chain improvements and continued strong customer demand. Net domestic sales increased during the six months ended June 30, 2023 to $530,487 from $379,986 for the comparable period in 2022, while net foreign sales increased to $52,052 from $37,059 during the same six-month period.
Costs of operations for the six months ended June 30, 2023 increased 33.6% to $512,194 from $383,331 for the comparable period in 2022, due to increased deliveries. Costs of operations decreased as a percentage of sales to 87.9%, compared to 91.9% for the comparable period in 2022, primarily due to the recognition of price increases on sales to customers that offset higher input costs.
Selling, general and administrative expenses for the six months ended June 30, 2023 increased to $37,403 from $25,037 for the comparable period in 2022 due to increased expenses associated with increased sales volumes, as well as additional executive compensation expense as discussed in the 8-K filed in April 2023 and approximately $2,506 in increased professional and legal fees associated with recent investor activity discussed in the 8-K filed in March 2023. As a percentage of sales, selling, general and administrative expenses for the six months ended June 30, 2023 increased to 6.4% from 6.0% in the comparable period in 2022.
Interest expense, net increased to $2,713 from $1,046 for the six months ended June 30, 2023 as compared to the prior year period. Increases in interest expense, net were primarily due to increased borrowings on our credit facility, increased interest rates and increases in floor plan interest payments.
For the six months ended June 30, 2023 the Company recognized a net foreign currency exchange gain of $611, compared to a net loss of $363 for the six months ended June 30, 2022, reflecting foreign currency gains and loss on transactions denominated in a currency other than the local entity’s functional currency.
The provision for income taxes for the six months ended June 30, 2023 and 2022 reflects a combined effective U.S. federal, state and foreign tax rate of 21.6% and 20.3%, respectively. The higher year over year rate was due to favorable tax adjustments in foreign tax jurisdictions in the prior year. The principal differences between the federal statutory tax rate and the effective tax rate consist primarily of state taxes, domestic tax credits, and tax differences on foreign earnings.
Liquidity and Capital Resources
Cash provided by operating activities was $2,681 for the six months ended June 30, 2023, compared to cash used in operating activities of $34,827 in the comparable period in 2022. Cash provided by or used in operating activities is generally attributable to the receipt of payments from our customers as settlement of their contractual obligation once we have fulfilled all performance obligations related to our contracts with them. These cash receipts are netted with payments for purchases of inventory, materials used in manufacturing, and other expenses that are necessary in the ordinary course of our operations, such as utilities and taxes. The change in net cash flows from operating activities during the six months ended June 30, 2023, in comparison to the six months ended June 30, 2022, is primarily due to increased net income and a stabilization of changes in operating assets and liabilities as a result of improved availability of purchased components.
Cash used in investing activities was $24,173 for the six months ended June 30, 2023 compared to $22,832 for the comparable period in 2022. The cash used in investing activities for the six months ended June 30, 2023 was primarily for the purchase of SHC. (See Note 3 to the Condensed Consolidated Financial Statements contained in this Report).