You are only entitled to the return of your earnest money if there is a "finance contingency" or similar clause in the contract permitting you to terminate the contract without penalty in the event you can't get or lose financing, and you fully comply with such provision's terms.  Otherwise, if you cannot or do not close for any reason, including a lack of financing, when the seller was ready and wiling to go ahead, the seller may keep the earnest money. The entire purpose of earnest money is 1) incentivize the buyer to go through with the sale, because he/she has money at stake; and 2) to give the seller a reason to take the deal and stop trying to sell the property to others by guarantying them at least some payment if the buyer defaults.If you do have a finance contingency or similar provision and are in compliance with it, so that under the terms of the contract, you should get your money back, if the seller will not comply, you can sue them for "breach of contract" for the money.