Check the retainer agreement for any "non-refundable" clauses. Read the entire agreement and make sure you understand it fully.
In general, the retainer is like a security deposit and billable hours are charged against it. The unused portion should be returned to you unless there is a clause that makes the retainer "non-refundable" or other language to that effect.
In reality, many attorneys estimate how much time they expect to expend on getting your case started and after any substantial work is done on your case you may find that much of your retainer is used up already. But each law office is different. So you should really be asking these questions of your prospective attorneys. it varies greatly. Ask how far will that retainer likely get you in your case. I know some people such as my own sister who hired a lawyer with a large retainer, after one court appearance she already owed them money! Over $5,000 for one routine court appearance! I would have completed the entire case for her for that fee. But of course i would not represent my own sister. You really need to investigate. Some attorneys can be VERY CREATIVE when they do their billing. Sometimes triple billing in other words in an 8 hour work day they will bill 24 hours: this is how they do it I am told from an associate at a law firm-- he was trained to bill like this-- on the phone on case 1; while holding a file just handed to him by his secretary on case 2 ; while making some notes on case 3 same 7 minutes (billed in MINIMUM 1/4 hour increments) = 45 minutes total --15 minutes per each of the 3 different cases). Many attorneys will say its not proper I don't know lets see the other responses.
*And don't forget the secretary's time walking the file to the attorney and the law clerk's time who took the phone call etc etc they all go on the bill too. So ask questions about the law firm's billing practices .
How a retainer fee is applied will be governed by the agreement under which the retainer fee is tendered. Normally, a retainer fee is an advance against future work. The value of any work performed is then deducted from the retainer fee (usually at the conclusion of the relationship), with any balance refunded. The retainer fee ensures that the attorney will be paid for his or her work. If the client falls behind in making timely payments on the attorney's bills, then the retainer fee may be used to pay the attorney's outstanding bills, even though the matter for which the attorney was retained has not yet reached a conclusion. In that instance, the attorney may then call upon the client to replenish the retainer as a condition of continuing to work for the client.
As we trial lawyers like to say "Objection, counsel is assuming facts not in evidence!" Namely, that there IS a retainer agreement. While I totally agree that there IS supposed to be one, not all attorneys actually give them. To be clear for this person asking the question: you should never give any lawyer ANY money without getting the terms of the representation in writing. And feel free to ask that the written agreement spell out the idea of refunds, how often you will be billed for hours spent, refundability, etc.
FYI, there is no standard rule or law about whether a retainer is "gone" as soon as paid, ie, it is a minimum fee. The written agreement governs.