diff --git a/bilby/core/sampler/dynesty.py b/bilby/core/sampler/dynesty.py
index edf6b8c85cff14cab4d03d3e3bc28748bfa9c150..2b6dc72c39ba1042036e8c45560aaf113e60dc77 100644
--- a/bilby/core/sampler/dynesty.py
+++ b/bilby/core/sampler/dynesty.py
@@ -209,6 +209,7 @@ class Dynesty(NestedSampler):
         if self.kwargs["verbose"]:
             print("")
 
+        check_directory_exists_and_if_not_mkdir(self.outdir)
         dynesty_result = "{}/{}_dynesty.pickle".format(self.outdir, self.label)
         with open(dynesty_result, 'wb') as file:
             pickle.dump(out, file)