diff --git a/core/includes/theme.inc b/core/includes/theme.inc
index 0edb028..a9f7578 100644
--- a/core/includes/theme.inc
+++ b/core/includes/theme.inc
@@ -2533,21 +2533,6 @@ function theme_meter($variables) {
 }
 
 /**
- * Returns HTML for an indentation div; used for drag and drop tables.
- *
- * @param $variables
- *   An associative array containing:
- *   - size: Optional. The number of indentations to create.
- */
-function theme_indentation($variables) {
-  $output = '';
-  for ($n = 0; $n < $variables['size']; $n++) {
-    $output .= '<div class="indentation">&nbsp;</div>';
-  }
-  return $output;
-}
-
-/**
  * @} End of "addtogroup themeable".
  */
 
@@ -3201,6 +3186,7 @@ function drupal_common_theme() {
     ),
     'indentation' => array(
       'variables' => array('size' => 1),
+      'template' => 'indentation',
     ),
     'html_tag' => array(
       'render element' => 'element',
diff --git a/core/modules/system/templates/indentation.html.twig b/core/modules/system/templates/indentation.html.twig
new file mode 100644
index 0000000..a9d2aa6
--- /dev/null
+++ b/core/modules/system/templates/indentation.html.twig
@@ -0,0 +1,14 @@
+{#
+/**
+ * @file
+ * Default theme implementation for an indentation div; used for drag and drop tables.
+ *
+ * Available variables:
+ * - size: Optional. The number of indentations to create.
+ *
+ * @see template_preprocess()
+ *
+ * @ingroup themeable
+ */
+#}
+{% for i in 1..size if size > 0 %}<div class="indentation">&nbsp;</div>{% endfor %}
