The shelf life of a cake varies from one day to four months depending on how the confection is prepared and stored. Generally, cakes made in a bakery last between two and four days in the refrigerator and one to two days when stored in the pantry.
Cakes with fresh fruit or whipped cream last one to two days when stored in the refrigerator. The best method of storing cake in a refrigerator is to wrap the cake in plastic or place it in an airtight container. Another way to extend a cake's shelf life is by storing it in the freezer. Cake lasts two to four months when frozen; for best results, a frozen cake should be stored in an airtight container without frosting or icing.