diff --git a/includes/conditional_fields.features.inc b/includes/conditional_fields.features.inc
index b998ce3..017e562 100644
--- a/includes/conditional_fields.features.inc
+++ b/includes/conditional_fields.features.inc
@@ -58,6 +58,19 @@ function conditional_fields_features_export_render($module_name, $data, $export
 
       foreach ($info['dependents'] as $dependent_field_name => $dependees) {
         foreach ($dependees as $dependee) {
+
+          // If we handle uuids, update the exported code to change id to uuids.
+          if (variable_get('c_fields_uuid', FALSE) && $dependee['options']['condition'] == 'value' && $dependee['options']['values_set'] == CONDITIONAL_FIELDS_DEPENDENCY_VALUES_WIDGET) {
+            // Load the field info to get the referenced entity type.
+            $field_info = field_info_field($dependee['dependee']);
+
+            // We get the info about the referenced entity type to know if it uses uuid.
+            $entity_info = (isset($field_info['settings']['target_type'])) ? entity_get_info($field_info['settings']['target_type']) : array();
+
+            // We try to get the uuid of the target, otherwise we don't override the default value.
+            // @TODO: 'target_id' only works with entityreference.
+            if (!empty($entity_info['uuid']) && isset($dependee['options']['value'][0]['target_id']) && $uuid = current(entity_get_uuid_by_id($field_info['settings']['target_type'], array($dependee['options']['value'][0]['target_id'])))) {
+              // Store the uuid of the select entity.
+              $dependee['options']['value'][0]['target_uuid'] = $dependee['options']['value_form'] = $uuid;
+
+              // Unset the normal stored value.
+              unset($dependee['options']['value'][0]['target_id']);
+            }
+          }
+
           $code[] = '';
           $code[] = '  $items["' . $option . ':' . $delta[$option] . '"] = array(';
           $code[] = "    'entity' => '" . $entity . "',";
@@ -111,6 +124,19 @@ function conditional_fields_features_rebuild($module) {
       $entity_instances = $instances[$field['entity']][$field['bundle']];
       $dependee_id = $entity_instances[$field['dependee']]['id'];
       $dependent_id = $entity_instances[$field['dependent']]['id'];
+
+      // If we handle uuids, update the given uuids to Drupal ids.
+      if (variable_get('c_fields_uuid', FALSE) && $field['options']['condition'] == 'value' && $field['options']['values_set'] == CONDITIONAL_FIELDS_DEPENDENCY_VALUES_WIDGET && array_key_exists('target_uuid', $field['options']['value'][0])) {
+        // Load the field info to get the referenced entity type.
+        $field_info = field_info_field($field['dependee']);
+
+        // Get the entity id's from the uuid.
+        $field['options']['value_form'] = $field['options']['value'][0]['target_id'] = current(entity_get_id_by_uuid($field_info['settings']['target_type'], array($field['options']['value'][0]['target_uuid'])));
+
+        // Unset the uuid setting as we don't store it in the db.
+        unset($field['options']['value'][0]['target_uuid']);
+      }
+
       conditional_fields_dependency_insert($dependee_id, $dependent_id, $field['options']);
     }
   }
