diff --git a/core/includes/common.inc b/core/includes/common.inc
index 9601c76..aa23a96 100644
--- a/core/includes/common.inc
+++ b/core/includes/common.inc
@@ -3238,9 +3238,9 @@ function drupal_build_css_cache($css) {
     // It's possible that the rewrite rules in .htaccess aren't working on this
     // server, but there's no harm (other than the time spent generating the
     // file) in generating the file anyway. Sites on servers where rewrite rules
-    // aren't working can set css_gzip_compression to FALSE in order to skip
+    // aren't working can set gzip_compression.css to FALSE in order to skip
     // generating a file that won't be used.
-    if (variable_get('css_gzip_compression', TRUE) && extension_loaded('zlib')) {
+    if (config('system.performance')->get('gzip_compression.css') && extension_loaded('zlib')) {
       if (!file_exists($uri . '.gz') && !file_unmanaged_save_data(gzencode($data, 9, FORCE_GZIP), $uri . '.gz', FILE_EXISTS_REPLACE)) {
         return FALSE;
       }
@@ -4757,9 +4757,9 @@ function drupal_build_js_cache($files) {
     // It's possible that the rewrite rules in .htaccess aren't working on this
     // server, but there's no harm (other than the time spent generating the
     // file) in generating the file anyway. Sites on servers where rewrite rules
-    // aren't working can set js_gzip_compression to FALSE in order to skip
+    // aren't working can set gzip_compression.js to FALSE in order to skip
     // generating a file that won't be used.
-    if (variable_get('js_gzip_compression', TRUE) && extension_loaded('zlib')) {
+    if (config('system.performance')->get('gzip_compression.js') && extension_loaded('zlib')) {
       if (!file_exists($uri . '.gz') && !file_unmanaged_save_data(gzencode($contents, 9, FORCE_GZIP), $uri . '.gz', FILE_EXISTS_REPLACE)) {
         return FALSE;
       }
diff --git a/core/modules/system/config/system.performance.yml b/core/modules/system/config/system.performance.yml
index 1eeb22a..8685f68 100644
--- a/core/modules/system/config/system.performance.yml
+++ b/core/modules/system/config/system.performance.yml
@@ -7,3 +7,6 @@ preprocess:
   js: '0'
 response:
   gzip: '0'
+gzip_compression:
+  css: '1'
+  js: '1'
diff --git a/core/modules/system/system.install b/core/modules/system/system.install
index e938128..0815642 100644
--- a/core/modules/system/system.install
+++ b/core/modules/system/system.install
@@ -2215,6 +2215,18 @@ function system_update_8032() {
 }
 
 /**
+ * coverts the css_gzip_compression, js_gzip_compression variables to Config API.
+ *
+ * @ingroup config_upgrade
+ */
+function system_update_8033() {
+  $variable_map = array(
+    'css_gzip_compression' => 'gzip_compression.css',
+    'js_gzip_compression' => 'gzip_compression.js'
+  );
+  update_variables_to_config('system.performance', $variable_map)
+}
+/**
  * @} End of "defgroup updates-7.x-to-8.x".
  * The next series of updates should start at 9000.
  */
