diff --git a/core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php b/core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php
index c9771d4..fdc37c7 100644
--- a/core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php
+++ b/core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php
@@ -62,10 +62,13 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
           // If there is a URL, this is an external link so always accessible.
           $access = AccessResult::allowed()->cachePerPermissions()->addCacheableDependency($entity);
           /** @var \Drupal\menu_link_content\MenuLinkContentInterface $entity */
-          // We allow access, but only if the link is accessible as well.
+          // We allow access when the link is accessible or the user has the
+          // 'link to any page' permission.
           if (($url_object = $entity->getUrlObject()) && $url_object->isRouted()) {
             $link_access = $this->accessManager->checkNamedRoute($url_object->getRouteName(), $url_object->getRouteParameters(), $account, TRUE);
-            $access = $access->andIf($link_access);
+            if (!$account->hasPermission('link to any page')) {
+              $access = $access->andIf($link_access);
+            }
           }
           return $access;
         }
diff --git a/core/modules/menu_link_content/src/Tests/MenuLinkContentFormTest.php b/core/modules/menu_link_content/src/Tests/MenuLinkContentFormTest.php
index 1bdc927..81aebc9 100644
--- a/core/modules/menu_link_content/src/Tests/MenuLinkContentFormTest.php
+++ b/core/modules/menu_link_content/src/Tests/MenuLinkContentFormTest.php
@@ -2,6 +2,7 @@
 
 namespace Drupal\menu_link_content\Tests;
 
+use Drupal\menu_link_content\Entity\MenuLinkContent;
 use Drupal\simpletest\WebTestBase;
 
 /**
@@ -25,7 +26,7 @@ class MenuLinkContentFormTest extends WebTestBase {
    */
   protected function setUp() {
     parent::setUp();
-    $web_user = $this->drupalCreateUser(array('administer menu'));
+    $web_user = $this->drupalCreateUser(array('administer menu', 'link to any page'));
     $this->drupalLogin($web_user);
   }
 
@@ -50,6 +51,23 @@ public function testMenuLinkContentForm() {
   }
 
   /**
+   * Tests the 'link to any page' permission for a restricted page.
+   */
+  public function testMenuLinkContentFormLinkToAnyPage() {
+    $menu_link = MenuLinkContent::create([
+      'title' => 'Menu link test',
+      'provider' => 'menu_link_content',
+      'menu_name' => 'admin',
+      'link' => ['uri' => 'internal:/user/login']
+    ]);
+    $menu_link->save();
+    // The user should be able to edit a menu link to the page, even though
+    // the user cannot access the page itself.
+    $this->drupalGet('/admin/structure/menu/item/' . $menu_link->id() . '/edit');
+    $this->assertResponse(200);
+  }
+
+  /**
    * Tests validation for the MenuLinkContentForm class.
    */
   public function testMenuLinkContentFormValidation() {
