diff --git a/data_entity/data_entity.module b/data_entity/data_entity.module
index b8e56f7..12fa90b 100644
--- a/data_entity/data_entity.module
+++ b/data_entity/data_entity.module
@@ -227,3 +227,72 @@ function data_entity_views_api() {
   );
 }
 
+/**
+ * Implements hook_feeds_processor_targets_alter().
+ *
+ * @see data_entity_feed_unique_callback()
+ */
+function data_entity_feeds_processor_targets_alter(&$targets, $entity_type, $bundle_name) {
+  // Get the information about this entity.
+  $entity_info = entity_get_info($entity_type);
+
+  // See if this is a Data entity.
+  if ($entity_info['module'] == 'data_entity') {
+    // Add a unique callback for each target field.
+    foreach ($targets as &$target) {
+      $target['unique_callbacks'][] = 'data_entity_feed_unique_callback';
+      $target['bundle_name'] = $bundle_name;
+      $target['optional_unique'] = TRUE;
+    }
+  }
+}
+
+/**
+ * Feeds unique callback for Data table field targets.
+ *
+ * @param FeedsSource $source
+ *   The Feed source.
+ * @param string $entity_type
+ *   Entity type for the entity to be processed.
+ * @param string $bundle
+ *   Bundle name for the entity to be processed.
+ * @param string $target
+ *   A string identifying the unique target on the entity.
+ * @param array $values
+ *   The unique values to be checked.
+ *
+ * @return int
+ *   The existing entity id, or 0 if not found.
+ *
+ * @see data_entity_feeds_processor_targets_alter().
+ * @see FeedsProcessor::existingEntityId()
+ */
+function data_entity_feed_unique_callback(FeedsSource $source, $entity_type, $bundle, $target, $values) {
+  // Get the information about this entity.
+  $entity_info = entity_get_info($entity_type);
+  // Extract the entity ID key.
+  $entity_id_key = $entity_info['entity keys']['id'];
+
+  // Attempt to load the table.
+  if ($table = data_get_table($entity_info['base table'])) {
+    // Get the single value out of the array. Not sure why it has to be an array
+    // but as we deal in database columns, we know it's always a single value.
+    $value = array_pop($values);
+
+    // Check if this value already exists in this table.
+    if ($record = $table->handler()->load(array($target => $value))) {
+      // Use the first record.
+      $record = reset($record);
+
+      // Determine the primary key value.
+      if (isset($record[$entity_id_key])) {
+        return $record[$entity_id_key];
+      }
+    }
+  }
+
+  // Nothing found.
+  // (Note docs are incorrect about return value here, see
+  // https://www.drupal.org/node/2397219).
+}
+
