jewelry, beauty and electronics with declines across all other product categories except apparel which remained flat. QVC International's net revenue decline in constant currency for the six months ended June 30, 2024 was primarily due to a 3.6% decrease in ASP across all markets. These declines were partially offset by a 3.8% increase in units shipped across all markets except Italy. For the six months ended June 30, 2024, QVC International experienced shipped sales growth in constant currency across beauty, jewelry and electronics with declines in all other categories.
QVC's cost of goods sold as a percentage of net revenue was 64.4% and 65.5% for the three months ended June 30, 2024 and 2023, respectively, and 64.7% and 66.7% for the six months ended June 30, 2024 and 2023, respectively. The decrease in cost of goods sold as a percentage of revenue for the three and six months ended June 30, 2024 is primarily due to product margin favorability across both segments and lower freight costs at QxH, partially offset by higher freight costs at QVC International. The product margin favorability for the three and six months ended June 30, 2024 was driven by the net impact of merchandising efforts including cost reduction and pricing actions, as well as mix within product categories and less inventory liquidation in the current period at QxH.
QVC's operating expenses are principally comprised of commissions, order processing and customer service expenses, credit card processing fees and telecommunications expenses. Operating expenses as a percentage of net revenue were 7.8% and 8.0% for the three months ended June 30, 2024 and 2023, respectively, and 7.9% and 8.0% for the six months ended June 30, 2024 and 2023, respectively. For the three and six months ended June 30, 2024, the decreases in operating expenses as a percent of sales are driven by lower commissions expense at QxH.
QVC's SG&A expenses (excluding stock-based compensation) include personnel, information technology, marketing and advertising expenses, production costs, and provision for doubtful accounts. Such expenses decreased $7 million for the three months ended June 30, 2024 and as a percentage of net revenue increased from 14.8% to 15.1%, as compared to the three months ended June 30, 2023. Such expenses decreased $15 million for the six months ended June 30, 2024, and as a percentage of net revenue increased from 14.6% to 14.8%, as compared to the same period in the prior year. For the three months ended June 30, 2024, the decrease was primarily due to an $11 million decrease in consulting expenses primarily at QxH and $4 million of favorability from foreign exchange rates. These decreases were partially offset by an $8 million increase in marketing costs, mainly at QxH. For the six months ended June 30, 2024, the decrease was primarily driven by a $28 million decrease in consulting expenses primarily at QxH and $6 million of favorability from foreign exchange rates. These decreases were partially offset by a $25 million increase in marketing costs at QxH. The decrease in consulting expenses for the three and six months ended June 30, 2024 related to investments in Project Athens made in the prior year.
QVC recorded restructuring costs of $18 million for the three and six months ended June 30, 2024 related to the shift in its information technology operating model. QVC recorded a gain of $211 million and $215 million for the three and six months ended June 30, 2023, respectively, in restructuring, penalties and fire related costs, net of recoveries. For the three months ended June 30, 2023, the gain primarily related to a $225 million gain on insurance proceeds received in excess of fire losses partially offset by $16 million of other fire related costs. For the six months ended June 30, 2023, the gain related to a $240 million gain on insurance proceeds received in excess of fire losses and a $15 million gain on the sale of the Rocky Mount property, partially offset by $27 million of other fire related costs and $13 million of restructuring costs related to workforce reduction.
QVC recorded a $1 million gain on sale of assets and sale leaseback transactions for the six months ended June 30, 2024 related to the sale leaseback of a property in Germany. QVC recorded $6 million and $119 million of gains on sales of assets and sale leaseback transactions for the three and six months ended June 30, 2023, respectively. The $6 million gain for the three months ended June 30, 2023 is primarily related to the sale of a channel positioning right. The $119 million gain for the six months ended June 30, 2023 is primarily related to the sale leaseback of two properties located in Germany and the U.K.
Stock-based compensation includes compensation related to options and restricted stock units granted to certain officers and employees. QVC recorded $2 million and $11 million for the three months ended June 30, 2024 and 2023, respectively, and $14 million and $20 million for the six months ended June 30, 2024 and 2023, respectively. The decrease in stock compensation expense for the three and six months ended June 30, 2024 is primarily related to changes in the market price of Qurate Retail’s Series A common stock.