diff --git a/helios/models.py b/helios/models.py
index 5ac4f387055f06490d33c1f5943b34b1aeaa766a..04a7f648d22ae906ca62489dcc9db755c1601c15 100644
--- a/helios/models.py
+++ b/helios/models.py
@@ -808,9 +808,14 @@ class Voter(HeliosModel):
     if self.voter_login_id:
       # for backwards compatibility with v3.0, and since it doesn't matter
       # too much if we hash the email or the unique login ID here.
-      return utils.hash_b64(self.voter_login_id)
+      value_to_hash = self.voter_login_id
     else:
-      return utils.hash_b64(self.voter_id)
+      value_to_hash = self.voter_id
+
+    try:
+      return utils.hash_b64(value_to_hash)
+    except:
+      return utils.hash_b64(value_to_hash.encode('latin-1'))
 
   @property
   def voter_type(self):