You can apply for a green card immediately after getting married if you marry a U.S. citizen. However, if your spouse is a green card holder (permanent resident), you will need to wait for a visa number to become available, which can take several years. Always consult with an immigration attorney for personalized advice.