diff --git a/core/modules/views/templates/views-view-grid.tpl.php b/core/modules/views/templates/views-view-grid.tpl.php
deleted file mode 100644
index 43ba37b..0000000
--- a/core/modules/views/templates/views-view-grid.tpl.php
+++ /dev/null
@@ -1,28 +0,0 @@
-<?php
-
-/**
- * @file
- * Default simple view template to display a rows in a grid.
- *
- * - $rows contains a nested array of rows. Each row contains an array of
- *   columns.
- *
- * @ingroup views_templates
- */
-?>
-<?php if (!empty($title)) : ?>
-  <h3><?php print $title; ?></h3>
-<?php endif; ?>
-<table <?php print $attributes; ?>>
-  <tbody>
-    <?php foreach ($rows as $row_number => $columns): ?>
-      <tr <?php print $row_classes[$row_number]; ?>>
-        <?php foreach ($columns as $column_number => $item): ?>
-          <td <?php print $column_classes[$row_number][$column_number]; ?>>
-            <?php print $item; ?>
-          </td>
-        <?php endforeach; ?>
-      </tr>
-    <?php endforeach; ?>
-  </tbody>
-</table>
diff --git a/core/modules/views/views.theme.inc b/core/modules/views/views.theme.inc
index 03398cb..b9fbb0f 100644
--- a/core/modules/views/views.theme.inc
+++ b/core/modules/views/views.theme.inc
@@ -751,7 +751,7 @@ function template_preprocess_views_view_grid(&$vars) {
         $row_classes['class'][] = 'row-last';
       }
     }
-    $row_classes = new Attribute($row_classes);
+    $vars['row_classes'][] = $row_classes;
 
     foreach ($rows[$row_number] as $column_number => $item) {
       $vars['column_classes'][$row_number][$column_number] = array();
diff --git a/core/modules/views/templates/views-view-grid.html.twig b/core/modules/views/templates/views-view-grid.html.twig
new file mode 100644
--- /dev/null
+++ b/core/modules/views/templates/views-view-grid.html.twig
@@ -0,0 +1,36 @@
+{#
+/**
+ * @file
+ * Default simple view template to display a rows in a grid.
+ *
+ * Available variables:
+ * - attributes: Remaining HTML attributes for the element.
+ * - attributes.class: HTML classes that can be used to style contextually
+ *    through CSS.
+ * - title: @todo
+ * - attributes: Remaining HTML attributes for the element.
+ * - attributes.class: HTML classes that can be used to style contextually
+ *    through CSS.
+ * - rows contains a nested array of rows. Each row contains an array of
+ *   columns.
+ *
+ * @ingroup views_templates
+ */
+#}
+{# using the square brackets because the rows array does not have structure data #}
+{% if title %}
+  <h3>{{ title }}</h3>
+{% endif %}
+<table class="{{ attributes.class }}"{{ attributes }}>
+  <tbody>
+    {% for row_number, columns in rows %}
+      <tr class="{{ row_classes[row_number]['class']|join(' ') }}">
+        {% for column_number, item in columns %}
+          <td class="{{ column_classes[row_number][column_number]|join(' ') }}">
+            {{ item }}
+          </td>
+        {% endfor %}
+      </tr>
+    {% endfor %}
+  </tbody>
+</table>
