You know how sometimes, we think certain foods last forever just because they seem to? Pickles fall into that category for many of us.

Yet the truth is that pickles, like all other foods, have a shelf life. Eventually, pickles do go bad — and unless you want to find yourself… well, in a pickle for eating them, you should know a thing or two about how long they last and how to store them.

Do Pickles Go Bad?

Yes, pickles go bad. Pickles may have a longer shelf life compared to many other foods, but that doesn’t mean they can be kept indefinitely.

As a general rule, an unopened jar of pickles can last for 1 year from the date of purchase when stored in the pantry. Once you open the jar, refrigerate the pickles to preserve their freshness. They typically last for 1 to 3 months in the fridge.

Food safety experts agree that as long as you’ve stored canned pickles correctly and the jar is intact, they can last well beyond their expiration date.

But don’t rely blindly on expiration dates or rules of thumb! When you open a jar of pickles, check it before eating it.

How to Tell If Pickles Have Gone Bad

Pickles must be kept in a sealed jar. If the lid is bulging or the jar spurts when you open it, don’t eat them. It’s important to keep food safety in mind when eating canned foods since they can cause botulism if not canned or stored correctly.

Look the pickles over and give them a good, inquisitive sniff after opening them. If they feel soft, look gross, or have a weird odor, chances are they’re no longer safe to eat. The same holds true for pickles with cloudy, murky brine. Trust your gut and discard them.

When it comes to texture, mushy or slimy pickles are not a good sign. Similarly, if you notice any mold growth or discoloration on your pickles, it’s time to toss them out. These are all clear indications that your pickles may be unsafe to eat.

How to Properly Store Pickles

Now that we’ve covered the shelf life of pickles, let’s go over the right way to store them.

Commercially-canned pickles have undergone thermal treatment and hermetic sealing to prevent the growth of bad bacteria and preserve their quality and freshness for a long period of time.

Unopened pickle jars are shelf-stable. To store them, label the date of purchase on the jar or lid with a marker and put them in the pantry. If you don’t have a pantry, store them in a cool and dry place, away from direct sunlight and sources of heat, such as in a cabinet, drawer, or closet.

Avoid storing pickles near heat sources, like your range or the part of the countertop above the dishwasher, and keep the pickles away from the back of your fridge or freezer. These appliances emit heat that can make the pickles lose their best quality sooner.

Remember that once you’ve opened a jar of pickles, everything changes. They’re no longer a shelf-stable food—they become perishable—and they need to be stored in the refrigerator. For best quality, keep the jar’s lid tightly sealed and use the pickles up shortly after opening.

The Odd One Out: Refrigerator Pickles

We focused a lot on canned (okay, jarred) pickles so far. But it’s important to talk about another type of pickle. The outlier.

Refrigerator pickles, whether you made them at home or bought them from the Jewish deli or refrigerated section of your local grocery store, are not the same as their canned counterparts.

As the name gives away, refrigerator pickles must be stored in the fridge. They are not heat processed and definitely not hermetically sealed, and are sold in plastic tubs. Generally speaking, they stay good for 3 to 4 weeks in the fridge.