No-bake cookie dough can last in the fridge for three to four weeks in a sealed container. However, it is safe to eat immediately after making it.