Thanks for your question.
If you were legally married in Costa Rica, your marriage is considered to be legally valid in the U.S. Obtaining a divorce after a foreign marriage is not much different than terminating a marriage that occurred anywhere in the United States.
Assuming you meet the residency requirements to obtain a divorce in your particular state(usually ranging from 30 days to 6 months), you would need to obtain a petition for divorce (many states have blank forms online) and file it in the county where you live along with a filing fee which varies from one court to another. Since you don't know where your spouse lives, she would likely have to be served with the complaint by publication, which entails running a legal advertisement in the newspaper in the area where you think she lives or last lived. She will have a certain period of time in which to file an answer to your divorce petition after service is deemed to have been completed.
Your case will be set for a hearing, the judge will ask you a few questions, and then your divorce will be final.
Hope this helps. Good luck.
DISCLAIMER: Answers from Experts on JustAnswer are not substitutes for the advice of an attorney. JustAnswer is a public forum and questions and responses are not private or confidential or protected by the attorney-client privilege. The Expert above is not your attorney, and the response above is not legal advice. You should not read this response to propose specific action or address specific circumstances, but only to give you a sense of general principles of law that might affect the situation you describe. Application of these general principles to particular circumstances must be done by a lawyer who has spoken with you in confidence, learned all relevant information, and explored various options. Before acting on these general principles, you should hire a lawyer licensed to practice law in the jurisdiction to which your question pertains.
The responses above are from individual Experts, not JustAnswer. The site and services are provided “as is”. To view the verified credential of an Expert, click on the “Verified” symbol in the Expert’s profile. This site is not for emergency questions which should be directed immediately by telephone or in-person to qualified professionals. Please carefully read the Terms of Service (last updated February 8, 2012).