Some work is handled on the basis of an hourly rate. The time spent on a case handled on this basis is itemized to the client and the client pays for the time expended by the attorney regardless of the results obtained. Some work is performed on a contingent fee basis which means the attorney will receive a percentage of the amount actually recovered. Personal injury claims are often handled in this fashion.
Some work is handled on the basis of a fixed fee for certain work.
In such a case a non-refundable fee is paid to retain the attorney. This money is utilized by the attorney to offset expenses of investigation and research. Any amount deposited less actual expenses is credited to the attorney fee if there is a successful result. Out of pocket expenses such as filing fees, deposition costs, expert fees, exhibit preparation costs, etc. The terms are spelled out in the attorney-client contract which the client will be required to sign.