An alien who is married to a U.S. citizen enjoys an unusual benefit: Instead of spending five years as a lawful permanent resident before applying to naturalize, you need to spend only three years; so long as you were married to, and living with the U.S. citizen for the entire three years. You do not need to have obtained your green card through this marriage.
As you may know, immigrants with lawful permanent residence must be able to satisfy certain eligibility criteria before applying for U.S. citizenship through the process known as naturalization. (This process involves filing Form N-400, Application for Naturalization).
The eligibility criteria include things like being a person of good moral character, being able to speak, read, and write English, passing a test in U.S. history and government, and more.
Of greater importance for this discussion, the eligibility criteria require that you have been a permanent resident for at least a certain amount of time before submitting your N-400. For most people, that's five years from the date of becoming a lawful permanent resident. (Literally speaking, you must count forward from the date you were either approved for a green card in the U.S. through the "adjustment of status" process" or entered the U.S. for the first time with your immigrant visa.)
However, the alien spouse of a U.S. citizen can apply to naturalize three years after having become a lawful permanent resident.
It's important to be aware of the condition within the law that you have been both married to and living with the U.S. citizen for the entire three years. If, for example, you and your U.S. citizen spouse have separated, divorced, or merely started living in different cities, then you are no longer eligible to use this exception.
Similarly, if your spouse was him- or herself a permanent resident at the beginning of those three years and only recently became a U.S. citizen, you must wait until your spouse has been a citizen for a full three years before making use of this exception.
Another requirement for U.S. citizenship is that you have spent half of your required time as a permanent resident actually living within the United States. For people who must spend five years as a permanent resident before applying, that means they must fill a physical presence requirement of two and a half years, or 30 months.
In keeping with the three-year rule, however, the amount of time that you must be physically present in the U.S. before applying to naturalize is one half of three years, or 18 months.
If you were married for less than two years when you first got approved for the green card, then you were probably given conditional rather than permanent residence to begin with. Conditional residence expires after two years. You would have needed to submit Form I-751 to U.S. Citizenship and Immigration Services (USCIS) in the 90 days before the expiration date in order to convert from conditional to permanent residence.
Assuming you did this successfully, your two years as a conditional resident count as if it were permanent residence. You would be able to apply for U.S. citizenship three years from the original approval date of your conditional residence.
If you have more questions concerning your citizenship eligibility or the application process, please consult with an experienced U.S. immigration attorney.