diff --git a/core/includes/common.inc b/core/includes/common.inc
index f1a7ce0..497d182 100644
--- a/core/includes/common.inc
+++ b/core/includes/common.inc
@@ -2340,7 +2340,7 @@ function l($text, $path, array $options = array()) {
   if (!isset($use_theme) && function_exists('theme')) {
     // Allow edge cases to prevent theme initialization and force inline link
     // rendering.
-    if (variable_get('theme_link', TRUE)) {
+    if (config('system.performance')->get('theme_link')) {
       drupal_theme_initialize();
       $registry = theme_get_registry(FALSE);
       // We don't want to duplicate functionality that's in theme(), so any
diff --git a/core/modules/system/config/system.performance.yml b/core/modules/system/config/system.performance.yml
index 7483921..20f39d0 100644
--- a/core/modules/system/config/system.performance.yml
+++ b/core/modules/system/config/system.performance.yml
@@ -8,3 +8,4 @@ preprocess:
   stale_file_threshold: '2592000'
 response:
   gzip: '0'
+theme_link: '1'
diff --git a/core/modules/system/system.install b/core/modules/system/system.install
index e414238..41a0254 100644
--- a/core/modules/system/system.install
+++ b/core/modules/system/system.install
@@ -2209,6 +2209,17 @@ function system_update_8034() {
 }
 
 /**
+ * Moves system theme settings from variable to config.
+ *
+ * @ingroup config_upgrade
+ */
+function system_update_8035() {
+  update_variables_to_config('system.performance', array(
+    'theme_link' => 'theme_link',
+  ));
+}
+
+/**
  * @} End of "defgroup updates-7.x-to-8.x".
  * The next series of updates should start at 9000.
  */
