diff --git a/src/Form/IndexAddFieldsForm.php b/src/Form/IndexAddFieldsForm.php
index 61f4be2..1c5790d 100644
--- a/src/Form/IndexAddFieldsForm.php
+++ b/src/Form/IndexAddFieldsForm.php
@@ -368,7 +368,7 @@ class IndexAddFieldsForm extends EntityForm {
       $parent_child_type = NULL;
       if ($property instanceof ComplexDataDefinitionInterface) {
         $can_be_indexed = FALSE;
-        $nested_properties = $property->getPropertyDefinitions();
+        $nested_properties = Utility::getNestedProperties($property);
         $main_property = $property->getMainPropertyName();
         if ($main_property && isset($nested_properties[$main_property])) {
           $parent_child_type = $property->getDataType() . '.';
diff --git a/src/Item/Field.php b/src/Item/Field.php
index 8580c59..be2b20e 100644
--- a/src/Item/Field.php
+++ b/src/Item/Field.php
@@ -377,7 +377,8 @@ class Field implements \IteratorAggregate, FieldInterface {
     if (!$property instanceof ComplexDataDefinitionInterface) {
       return NULL;
     }
-    return $this->getNestedDefinition($property->getPropertyDefinitions(), $keys);
+    $nested_properties = Utility::getNestedProperties($property);
+    return $this->getNestedDefinition($nested_properties, $keys);
   }
 
   /**
diff --git a/src/Utility.php b/src/Utility.php
index 8e8ccda..5da5de3 100644
--- a/src/Utility.php
+++ b/src/Utility.php
@@ -10,6 +10,7 @@ namespace Drupal\search_api;
 use Drupal\Component\Render\FormattableMarkup;
 use Drupal\Core\Config\ConfigImporter;
 use Drupal\Core\Entity\EntityInterface;
+use Drupal\Core\Entity\TypedData\EntityDataDefinitionInterface;
 use Drupal\Core\TypedData\ComplexDataDefinitionInterface;
 use Drupal\Core\TypedData\ComplexDataInterface;
 use Drupal\Core\TypedData\DataDefinitionInterface;
@@ -746,4 +747,28 @@ class Utility {
     return static::splitPropertyPath($combined_id, TRUE, IndexInterface::DATASOURCE_ID_SEPARATOR);
   }
 
+  /**
+   * Get nested properties.
+   *
+   * If we have bundles, we have to arrive up to the fields that are in the
+   * bundle.
+   *
+   * @param \Drupal\Core\TypedData\DataDefinitionInterface[] $property
+   *   The base definition.
+   *
+   * @return \Drupal\Core\Field\FieldDefinitionInterface[]
+   *   The nested properties and fields of the entity.
+   */
+  public static function getNestedProperties($property) {
+    $nested_properties = $property->getPropertyDefinitions();
+    if ($property instanceof EntityDataDefinitionInterface) {
+      $bundles = \Drupal::entityManager()->getBundleInfo($property->getEntityTypeId());
+      foreach ($bundles as $bundle => $bundle_label) {
+        $bundle_properties = \Drupal::entityManager()->getFieldDefinitions($property->getEntityTypeId(), $bundle);
+        $nested_properties += $bundle_properties;
+      }
+    }
+    return $nested_properties;
+  }
+
 }
