The two biggest chunks of closing costs are the down payment for the house and your lawyer's fees. Before you close on the house, you'll need to know how much these are going to be (sometimes you'll need to pay by certified check). In addition to writing up a contract, which specifies exactly which piece of property is being sold by which seller to which buyer on what terms and what exactly is included in the sale (appliances, furniture, yard and its contents, phone line, etc.), your lawyer will also performs a title check to make sure that the seller of the property is really the owner and that he or she has the right to transfer ownership to you. The lawyer will also investigate if there are any other legal claims on the property.
There will be a large stack of papers for you to sign at the time of closing, including the settlement statement, title insurance, the sales contract, homeowner's insurance (which you've already secured, but which now starts covering the house), and the title to the property. You may have to initial each page of the contract, signing your full name at the end; so make sure you allow yourself enough time to go through all of this paperwork (a typical closing can take a few hours). Arrive at the lawyer's office well rested, as occasionally something unexpected comes up and you may have to make a decision or offer an alternative choice. Last-minute changes are not unheard of at house closings, so you have to be prepared for any eventuality.