diff --git a/goffice/gtk/go-locale-sel.c b/goffice/gtk/go-locale-sel.c
index 2ff124c..34ed037 100644
--- a/goffice/gtk/go-locale-sel.c
+++ b/goffice/gtk/go-locale-sel.c
@@ -84,9 +84,10 @@ lgroups_order (const void *_a, const void *_b)
 
 typedef struct {
 	gchar const *locale_title;
-	gchar const *locale;
+	gchar const *base_locale;  /* "xx_XX" */
 	LocaleGroup const lgroup;
 	gboolean available;
+	gchar *actual_locale;      /* "xx_XX" or "xx_XX.utf8" */
 } LocaleInfo;
 
 static LocaleInfo locale_trans_array[] = {
@@ -421,7 +422,7 @@ ls_build_menu (GOLocaleSel *ls)
 					gtk_widget_show (subitem);
 					gtk_menu_shell_append (GTK_MENU_SHELL (submenu),  subitem);
 					g_object_set_data (G_OBJECT (subitem), LOCALE_NAME_KEY,
-							   (gpointer)(locale_trans->locale));
+							   (gpointer)(locale_trans->actual_locale));
 					cnt++;
 			}
 			locale_trans++;
@@ -499,21 +500,28 @@ ls_class_init (GtkWidgetClass *widget_klass)
 	locale_hash =
 		g_hash_table_new_full (go_ascii_strcase_hash,
 				       go_ascii_strcase_equal,
-				       (GDestroyNotify)g_free,
+				       NULL,
 				       NULL);
 
 	oldlocale = g_strdup (setlocale (LC_ALL, NULL));
 	for (ci = locale_trans_array; ci->locale_title; ci++) {
-		ci->available = (setlocale (LC_ALL, ci->locale) != NULL);
-		g_hash_table_insert (locale_hash, (char *)ci->locale, ci);
+		const char *locale = ci->base_locale;
+		char *localeutf8 = g_strconcat (locale, ".utf8", NULL);
+		ci->available = (setlocale (LC_ALL, localeutf8) != NULL);
+		if (ci->available) {
+			ci->actual_locale = localeutf8;
+		} else {
+			ci->available = (setlocale (LC_ALL, locale) != NULL);
+			ci->actual_locale = g_strdup (locale);
+			g_free (localeutf8);
+		}
+		g_hash_table_insert (locale_hash, ci->actual_locale, ci);
 	}
 
 	/* Handle the POSIX/C alias.  */
-	{
-		LocaleInfo *ci = g_hash_table_lookup (locale_hash, "C");
-		g_assert (ci != NULL);
+	ci = g_hash_table_lookup (locale_hash, "C");
+	if (ci)
 		g_hash_table_insert (locale_hash, (char *)"POSIX", ci);
-	}
 
 	setlocale (LC_ALL, oldlocale);
 	g_free (oldlocale);
@@ -606,7 +614,7 @@ go_locale_sel_set_locale (GOLocaleSel *ls, const char *locale)
 	if (!ci)
 		return FALSE;
 
-	locale = ci->locale;
+	locale = ci->actual_locale;
 	if (!locale)
 		return FALSE;
 
