Closing costs are incurred and paid at Closing. Both the buyer and the seller incur them.
Generally speaking, the seller’s costs at closing include the excise tax (1.78% here in the Seattle area), one half the escrow fee, the costs of a title insurance policy to benefit the buyer, and various recording and miscellaneous fees (a few hundred bucks). All of those costs equal about 3% of the sale price. The buyer’s closing costs include the other half of the escrow fee, a title insurance policy to benefit the lender, the lender’s costs and fees, and various recording and miscellaneous fees (again, a few hundred bucks). Most of the buyer’s costs are incurred by the lender, unless the buyer has gotten a great deal on a loan.
For the seller, costs are paid out of the proceeds of the sale. So they are no big deal for the seller. The buyer, though, has to bring additional money to escrow to pay the buyer’s closing costs.