diff --git a/Trajectories/trajectories.py b/Trajectories/trajectories.py
index 046a94b666f7a4e7bc8fd654c80b233d13164b25..ad9d141e98a26a446e3b3fc8591425e3c5e22388 100755
--- a/Trajectories/trajectories.py
+++ b/Trajectories/trajectories.py
@@ -172,13 +172,13 @@ for t in traj_vert_ind:
 print("Saving...")
 
 with open("traj_segm.json", "w") as outfile:
-    json.dump(traj_segm, outfile, indent = 4)
+    json.dump(traj_segm, outfile, separators = (',', ':'))
 
 print("Created traj_segm.json.")
 
 with open("expanded_traj.json", "w") as outfile:
     json.dump({"e_overestim": g.gp.e_overestim, "traj": expanded_traj},
-              outfile, indent = 4)
+              outfile, separators = (',', ':'))
 
 print("Created expanded_traj.json.")
 print('Done')