The escrow company will order the payoff from your mortgage company. The interest is prorated to the day of funding/closing. There may be additional fees included in your payoff that the lender will charge, such as:
Often times, the escrow company will request the payoff with a few additional days factored in to act as a cushion. The escrow company may (should) order an updated payoff closer to the signing date in order to provide the most accurate figures possible. The lender being refinanced will refund any difference in your favor. In addition, if you have an escrow reserve account for taxes and insurance, you will receive a refund from the lender in approximately 6-8 weeks after closing.
At your signing appointment, ask to receive a copy of your payoff statement. Check to see how recently it was requested. If it was ordered at the beginning of the transaction and you have since made a mortgage payment, you can ask the closer to order an updated statement prior to closing (with a refinance, there is a three day right of rescission that takes place, so there should be enough time for this to take place with most lenders).