diff --git a/core/lib/Drupal/Core/Config/ConfigUUIDException.php b/core/lib/Drupal/Core/Config/ConfigUUIDException.php
new file mode 100644
index 0000000..cc81a95
--- /dev/null
+++ b/core/lib/Drupal/Core/Config/ConfigUUIDException.php
@@ -0,0 +1,15 @@
+<?php
+
+/**
+ * @file
+ * Contains \Drupal\Core\Config\ConfigUUIDException.
+ */
+
+namespace Drupal\Core\Config;
+
+/**
+ * Exception thrown when a config object UUID causes a conflict.
+ */
+class ConfigUUIDException extends ConfigException {
+
+}
diff --git a/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php b/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php
index 90e9496..e22f451 100644
--- a/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php
+++ b/core/lib/Drupal/Core/Config/Entity/ConfigEntityBase.php
@@ -8,6 +8,7 @@
 namespace Drupal\Core\Config\Entity;
 
 use Drupal\Core\Entity\Entity;
+use Drupal\Core\Config\ConfigUUIDException;
 
 /**
  * Defines a base configuration entity class.
diff --git a/core/lib/Drupal/Core/Config/Entity/ConfigStorageController.php b/core/lib/Drupal/Core/Config/Entity/ConfigStorageController.php
index 1ce4456..a7eb48e 100644
--- a/core/lib/Drupal/Core/Config/Entity/ConfigStorageController.php
+++ b/core/lib/Drupal/Core/Config/Entity/ConfigStorageController.php
@@ -8,6 +8,7 @@
 namespace Drupal\Core\Config\Entity;
 
 use Drupal\Component\Uuid\Uuid;
+use Drupal\Core\Entity\Query\QueryFactory;
 use Drupal\Core\Entity\EntityInterface;
 use Drupal\Core\Entity\EntityControllerInterface;
 use Drupal\Core\Entity\EntityMalformedException;
@@ -16,6 +17,7 @@
 use Drupal\Core\Config\ConfigFactory;
 use Drupal\Core\Config\StorageInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
+use Drupal\Core\Config\ConfigUUIDException;
 
 /**
  * Defines the storage controller class for configuration entities.
@@ -95,6 +97,13 @@ class ConfigStorageController implements EntityStorageControllerInterface, Entit
   protected $configStorage;
 
   /**
+   * The entity query factory.
+   *
+   * @var \Drupal\Core\Entity\Query\QueryFactory
+   */
+  protected $entityQueryFactory;
+
+  /**
    * Constructs a ConfigStorageController object.
    *
    * @param string $entity_type
@@ -105,8 +114,10 @@ class ConfigStorageController implements EntityStorageControllerInterface, Entit
    *   The config factory service.
    * @param \Drupal\Core\Config\StorageInterface $config_storage
    *   The config storage service.
+   * @param \Drupal\Core\Entity\Query\QueryFactory $entity_query_factory
+   *   The entity query factory.
    */
-  public function __construct($entity_type, array $entity_info, ConfigFactory $config_factory, StorageInterface $config_storage) {
+  public function __construct($entity_type, array $entity_info, ConfigFactory $config_factory, StorageInterface $config_storage, QueryFactory $entity_query_factory) {
     $this->entityType = $entity_type;
     $this->entityInfo = $entity_info;
     $this->hookLoadArguments = array();
@@ -121,6 +132,7 @@ public function __construct($entity_type, array $entity_info, ConfigFactory $con
 
     $this->configFactory = $config_factory;
     $this->configStorage = $config_storage;
+    $this->entityQueryFactory = $entity_query_factory;
   }
 
   /**
@@ -131,7 +143,8 @@ public static function createInstance(ContainerInterface $container, $entity_typ
       $entity_type,
       $entity_info,
       $container->get('config.factory'),
-      $container->get('config.storage')
+      $container->get('config.storage'),
+      $container->get('entity.query')
     );
   }
 
@@ -485,6 +498,23 @@ public function save(EntityInterface $entity) {
    * Used before the entity is saved and before invoking the presave hook.
    */
   protected function preSave(EntityInterface $entity) {
+    // Ensure this entity's UUID does not exist with a different ID, regardless
+    // of whether it's new or updated.
+    $matching_entities = $this->entityQueryFactory->get($this->entityType)
+      ->condition('uuid', $entity->uuid())
+      ->execute();
+    $matched_entity = reset($matching_entities);
+    if (!empty($matched_entity) && ($matched_entity != $entity->id())) {
+      throw new ConfigUUIDException(sprintf('Attempt to save a configuration object %s with UUID %s when this UUID is already used for %s', $this->id(), $this->uuid(), $matched_entity));
+    }
+
+    if (!$entity->isNew()) {
+      $original = $this->loadUnchanged($entity->id());
+      // Ensure that the UUID cannot be changed for an existing entity.
+      if ($original && $original->uuid() != $entity->uuid()) {
+        throw new ConfigUUIDException(sprintf('Attempt to save a configuration entity %s with UUID %s when this entity already exists with UUID %s', $entity->id(), $entity->uuid(), $original->uuid()));
+      }
+    }
   }
 
   /**
diff --git a/core/modules/config/lib/Drupal/config/Tests/ConfigEntityStorageControllerTest.php b/core/modules/config/lib/Drupal/config/Tests/ConfigEntityStorageControllerTest.php
new file mode 100644
index 0000000..efb9a14
--- /dev/null
+++ b/core/modules/config/lib/Drupal/config/Tests/ConfigEntityStorageControllerTest.php
@@ -0,0 +1,64 @@
+<?php
+
+/**
+ * @file
+ * Contains \Drupal\config\Tests\ConfigEntityStorageControllerTest.
+ */
+
+namespace Drupal\config\Tests;
+
+use Drupal\simpletest\DrupalUnitTestBase;
+use Drupal\Component\Uuid\Uuid;
+use Drupal\Core\Config\ConfigUUIDException;
+
+/**
+ * Tests importing config entity data when the ID or UUID matches existing data.
+ */
+class ConfigEntityStorageControllerTest extends DrupalUnitTestBase {
+
+  /**
+   * Modules to enable.
+   *
+   * @var array
+   */
+  public static $modules = array('config_test');
+
+  public static function getInfo() {
+    return array(
+      'name' => 'Configuration entity UUID conflict',
+      'description' => 'Tests staging and importing config entities with IDs and UUIDs that match existing config.',
+      'group' => 'Configuration',
+    );
+  }
+
+  /**
+   * Tests importing fields and instances with changed IDs or UUIDs.
+   */
+  public function testUUIDConflict() {
+    $entity_type = 'config_test';
+    $id = 'test_1';
+    // Load the original field and instance entities.
+    entity_create($entity_type, array('id' => $id))->save();
+    $entity = entity_load($entity_type, $id);
+
+    $original_properties = $entity->getExportProperties();
+
+    // Override with a new UUID and try to save.
+    $uuid = new Uuid();
+    $new_uuid = $uuid->generate();
+    $entity->set('uuid', $new_uuid);
+
+    try {
+      $entity->save();
+      $this->fail('Exception thrown when attempting to save a configuration entity with a UUID that does not match the existing UUID.');
+    }
+    catch (ConfigUUIDException $e) {
+      $this->pass(format_string('Exception thrown when attempting to save a configuration entity with a UUID that does not match existing data: %e.', array('%e' => $e)));
+    }
+
+    // Ensure that the config entity was not corrupted.
+    $entity = entity_load('config_test', $entity->id(), TRUE);
+    $this->assertIdentical($entity->getExportProperties(), $original_properties);
+  }
+
+}
diff --git a/core/modules/image/lib/Drupal/image/Plugin/Core/Entity/ImageStyle.php b/core/modules/image/lib/Drupal/image/Plugin/Core/Entity/ImageStyle.php
index 60f020e..93cceab 100644
--- a/core/modules/image/lib/Drupal/image/Plugin/Core/Entity/ImageStyle.php
+++ b/core/modules/image/lib/Drupal/image/Plugin/Core/Entity/ImageStyle.php
@@ -55,6 +55,13 @@ class ImageStyle extends ConfigEntityBase implements ImageStyleInterface {
   public $label;
 
   /**
+   * The UUID for this entity.
+   *
+   * @var string
+   */
+  public $uuid;
+
+  /**
    * The array of image effects for this image style.
    *
    * @var string
