Removing all “_layouts/15/start.aspx#/” in Sharepoint URL

By | April 20, 2015

Do you want to remove that ugly additional URL “_layouts/15/start.aspx#/” on your SharePoint web address? Before doing so do you really need to do it? Do you even know what does that URL mean? Well if you don’t have a read here what it is for so you understand the impact of removing them.  In a gist, it makes your pages load faster by processing only the differences (or delta) between the current page and the requested page.

Now that you know and might have valid reasons on why you want to remove them go ahead and start doing so.

You can disable the feature by going to Site Settings -> Manage Site Features and disable the Minimal Download Strategy Feature.

01 Manage Site Features

02 Minimal Download Strategy

03 Deactivate

You can also do it in PowerShell by using the command below

Enable-SPFeature -Identity "87294c72-f260-42f3-a41b-981a2ffce37a" -url "http://www.yoursharepoint.com" -Force -Confirm:$False

That ugly GUID after the identity is the Id for the MDSFeature.

But take note both steps will disable the feature only on the site you are in, you will have to do this on all SubSites and SiteCollections, so to make your life easier I made a script to do that on all SubSites and SiteCollections and here is how it goes.

$sharepointServer = "http://www.yoursharepoint.com"
$webApplication Get-SPWebApplication -Identity $sharepointServer
$sharepointFeature = "87294c72-f260-42f3-a41b-981a2ffce37a"
$siteCollection = $webApplication | Get-SPSite -limit all 
 
foreach ($site in $siteCollection)
{
    $webs = $site | Get-SPweb -limit all
    foreach ($web in $webs)
        {
            $url = $web.URL
            Write-Host "Disabling Feature in URL = " $url -foregroundcolor "WHITE"
            Enable-SPFeature -Identity $sharepointFeature -url $url -Force -Confirm:$False
        }
}

Save the codes as Deactivate.ps1 and run it on SharePoints powershell

05 Deactivate All

You might see some errors like the one above, don’t worry about it because it means that the feature on that site was already disabled, meaning not activated.  For activated ones it will deactivate it.

Recommended

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.