Store-bought fondant lasts two years in an airtight container. Seriously. That stuff is practically immortal.
Homemade fondant? That’s a different story. It only lasts two to three weeks at room temperature.
The secret is stabilizers. Commercial fondant is packed with preservatives and glycerin that stop it from drying out or molding.