diff --git a/src/keyfile.c b/src/keyfile.c
index 6932982..9fddde9 100644
--- a/src/keyfile.c
+++ b/src/keyfile.c
@@ -521,7 +521,7 @@ static void save_dialog_prefs(GKeyFile *config)
 }
 
 
-static void save_ui_prefs(GKeyFile *config)
+static void save_ui_prefs(GKeyFile *config, GKeyFile *config_session)
 {
 	g_key_file_set_boolean(config, PACKAGE, "sidebar_visible", ui_prefs.sidebar_visible);
 	g_key_file_set_boolean(config, PACKAGE, "statusbar_visible", interface_prefs.statusbar_visible);
@@ -559,7 +559,7 @@ static void save_ui_prefs(GKeyFile *config)
 		gtk_window_get_size(GTK_WINDOW(main_widgets.window), &ui_prefs.geometry[2], &ui_prefs.geometry[3]);
 		wstate = gdk_window_get_state(gtk_widget_get_window(main_widgets.window));
 		ui_prefs.geometry[4] = (wstate & GDK_WINDOW_STATE_MAXIMIZED) ? 1 : 0;
-		g_key_file_set_integer_list(config, PACKAGE, "geometry", ui_prefs.geometry, 5);
+    g_key_file_set_integer_list(config_session, PACKAGE, "geometry", ui_prefs.geometry, 5);
 	}
 
 	g_key_file_set_string(config, PACKAGE, "custom_date_format", ui_prefs.custom_date_format);
@@ -576,22 +576,25 @@ static void save_ui_prefs(GKeyFile *config)
 void configuration_save(void)
 {
 	GKeyFile *config = g_key_file_new();
+  GKeyFile *config_session = g_key_file_new();
 	gchar *configfile = g_strconcat(app->configdir, G_DIR_SEPARATOR_S, "geany.conf", NULL);
+  gchar *configfile_session = g_strconcat(app->configdir, G_DIR_SEPARATOR_S, "geany_session.conf", NULL);
 	gchar *data;
 
 	g_key_file_load_from_file(config, configfile, G_KEY_FILE_NONE, NULL);
+  g_key_file_load_from_file(config_session, configfile_session, G_KEY_FILE_NONE, NULL);
 
 	/* this signal can be used e.g. to prepare any settings before Stash code reads them below */
 	g_signal_emit_by_name(geany_object, "save-settings", config);
 
 	save_dialog_prefs(config);
-	save_ui_prefs(config);
-	project_save_prefs(config);	/* save project filename, etc. */
-	save_recent_files(config, ui_prefs.recent_queue, "recent_files");
-	save_recent_files(config, ui_prefs.recent_projects_queue, "recent_projects");
+  save_ui_prefs(config, config_session);
+  project_save_prefs(config_session); /* save project filename, etc. */
+  save_recent_files(config_session, ui_prefs.recent_queue, "recent_files");
+  save_recent_files(config_session, ui_prefs.recent_projects_queue, "recent_projects");
 
 	if (cl_options.load_session)
-		configuration_save_session_files(config);
+    configuration_save_session_files(config_session);
 #ifdef HAVE_VTE
 	else if (vte_info.have_vte)
 	{
@@ -600,13 +603,20 @@ void configuration_save(void)
 	}
 #endif
 
-	/* write the file */
+  /* write the config file */
 	data = g_key_file_to_data(config, NULL, NULL);
 	utils_write_file(configfile, data);
 	g_free(data);
 
+  /* write the session config file */
+  data = g_key_file_to_data(config_session, NULL, NULL);
+  utils_write_file(configfile_session, data);
+  g_free(data);
+
 	g_key_file_free(config);
 	g_free(configfile);
+  g_key_file_free(config_session);
+  g_free(configfile_session);
 }
 
 
@@ -907,7 +917,7 @@ static void load_dialog_prefs(GKeyFile *config)
 }
 
 
-static void load_ui_prefs(GKeyFile *config)
+static void load_ui_prefs(GKeyFile *config, GKeyFile *config_session)
 {
 	gint *geo;
 	gsize geo_len;
@@ -950,7 +960,7 @@ static void load_ui_prefs(GKeyFile *config)
 				_("Type here what you want, use it as a notice/scratch board"));
 	scribble_pos = utils_get_setting_integer(config, PACKAGE, "scribble_pos", -1);
 
-	geo = g_key_file_get_integer_list(config, PACKAGE, "geometry", &geo_len, NULL);
+  geo = g_key_file_get_integer_list(config_session, PACKAGE, "geometry", &geo_len, NULL);
 	if (! geo || geo_len < 5)
 	{
 		ui_prefs.geometry[0] = -1;
@@ -1008,15 +1018,15 @@ void configuration_save_default_session(void)
  */
 void configuration_reload_default_session(void)
 {
-	gchar *configfile = g_build_filename(app->configdir, "geany.conf", NULL);
-	GKeyFile *config = g_key_file_new();
+  gchar *configfile_session = g_build_filename(app->configdir, "geany_session.conf", NULL);
+  GKeyFile *config_session = g_key_file_new();
 
-	g_key_file_load_from_file(config, configfile, G_KEY_FILE_NONE, NULL);
-	g_free(configfile);
+  g_key_file_load_from_file(config_session, configfile_session, G_KEY_FILE_NONE, NULL);
+  g_free(configfile_session);
 
-	configuration_load_session_files(config, FALSE);
+  configuration_load_session_files(config_session, FALSE);
 
-	g_key_file_free(config);
+  g_key_file_free(config_session);
 }
 
 
@@ -1024,6 +1034,8 @@ gboolean configuration_load(void)
 {
 	gchar *configfile = g_build_filename(app->configdir, "geany.conf", NULL);
 	GKeyFile *config = g_key_file_new();
+  gchar *configfile_session = g_build_filename(app->configdir, "geany_session.conf", NULL);
+  GKeyFile *config_session = g_key_file_new();
 
 	if (! g_file_test(configfile, G_FILE_TEST_IS_REGULAR))
 	{	/* config file does not (yet) exist, so try to load a global config file which may be */
@@ -1033,11 +1045,13 @@ gboolean configuration_load(void)
 	}
 	g_key_file_load_from_file(config, configfile, G_KEY_FILE_NONE, NULL);
 	g_free(configfile);
+  g_key_file_load_from_file(config_session, configfile_session, G_KEY_FILE_NONE, NULL);
+  g_free(configfile_session);
 
 	load_dialog_prefs(config);
-	load_ui_prefs(config);
-	project_load_prefs(config);
-	configuration_load_session_files(config, TRUE);
+  load_ui_prefs(config, config_session);
+  project_load_prefs(config_session);
+  configuration_load_session_files(config_session, TRUE);
 
 	/* this signal can be used e.g. to delay building UI elements until settings have been read */
 	g_signal_emit_by_name(geany_object, "load-settings", config);
