If you have an attorney or lawyer on retainer the attorney or lawyer should return the retainer within 20 to 30 days.
If the lawyer or attorney hasn't returned the retainer within 30 days then it would be a good idea to contact the attorney or lawyer about the retainer.
A reasonable time frame for a lawyer or attorney to return a retainer is 30 to 45 days which allows the attorney or lawyer time to prepare a final invoice and refund any balance left.
If they haven't returned the retainer within 45 days then I would be concerned but not until then.
It depends on how backed up the attorney or lawyer is but most lawyers or attorneys will return the retainer before 45 days.