Assuming, you are a permanent resident, you can apply for citizenship 3 months prior to the 5th year or 3rd year (via marriage) depending on how you got your green-card. However, remember there are other rules like staying in the same place 3 months prior to applying, at least staying in USA at least half the time as green card holder etc. Consult a licensed attorney for your unique case.