Minimal Download Strategy Feature in SharePoint 2013
Microsoft has introduced a new feature in SharePoint Server 2013 called the Minimal Download Strategy (MDS). In this article I would briefly talk about what this feature does and how it has changed the way SharePoint pages are loaded.
The MDS feature improves performance of your SharePoint sites in many ways. Although SharePoint 2010 made some improvements, SharePoint in general has been very slow at loading pages. One of the reasons why SharePoint has been slow is that it loads the entire page for every single action that the user takes. In SharePoint 2013 Microsoft has introduced MDS. With this feature, initially SharePoint takes a bit longer to load the site but once it has been loaded you will notice that navigating around the site is so much faster than any of the previous SharePoint versions.
If you are interested in all the gory details about this feature then you should read Microsoft MVP Wictor Wilén’s article SharePoint 2013 – Introduction to the Minimal Download Strategy (MDS). If you are a developer then you must read Wictor’s article. According to Wictor, by default, MDS is enabled on Team sites, Community sites and a few other sites in SharePoint 2013. Once this feature is enabled on a site, all pages for that site are rendered through the /_layouts/15/start.aspx page. As Wictor explains in his article:
In simple words, once the page has been loaded, all subsequent requests only load the delta (i.e. parts of the page that have been changed) which makes the page load faster. As I mentioned earlier this feature adds /_layouts/15/start.aspx to the URL. Unfortunately this seems to break (disable) the Connect to Outlook link on a SharePoint calendar. You can read my article on a possible workaround: How to Fix the Disabled “Connect to Outlook” link in SharePoint 2013.
NOTE: MDS is not enabled on the publishing sites in SharePoint 2013 because it is not compatible with publishing sites.
The MSDN article Minimal Download Strategy overview lists the following benefits of MDS.
Using MDS provides several benefits, including:
Speed: This is the main objective of MDS. When you are using MDS, the browser doesn’t have to reprocess the chrome user interface (UI). MDS also reduces the payload compared to a full page load.
Smooth transitions: By updating only the areas that change, you draw the user’s eye toward these areas, as opposed to a full page load where the whole page “flashes.” When the whole page is updated, the user must parse it in its entirety to detect what is new. Users have an easier time navigating a site that only updates the areas that changed from the previous page.
Browser navigation controls: Other AJAX-based systems confuse the previous and next buttons in browsers. Because MDS updates the URL in the browser window, the previous and next buttons work just as they are supposed to.
Backward compatibility: The MDS engine either provides MDS navigation immediately or detects when it isn’t possible. In the case where MDS navigation isn’t possible, a full page load occurs instead. This process is called failover, and it ensures that all pages render properly regardless of whether they contain MDS-compliant components. MDS also works nicely with search engines because the href attribute of anchor tags uses the regular, non MDS-formatted URLs. Instead, the MDS engine in the client captures the onclick event and uses it to communicate with the server.
Some Interesting Observations
If you want to know if a site has MDS enabled simply look in the URL. If the URL has _layouts/15/start.aspx# then the site has MDS enabled. If you enable SharePoint Server Publishing at the site level, which requires that you first enable the SharePoint Server Publishing Infrastructure feature at the Site Collection level, you will notice that the URL for Calendar will no longer have _layouts/15/start.aspx#. This is because, as stated earlier in this article, MDS is not supported for publishing sites.
One interesting thing is that if you go back and disable SharePoint Server Publishing at the site level, you will notice that MDS is automatically enabled. That’s nice. If for some reason you don’t see MDS activated, you can manually activate it.
In my article How to Fix the Disabled “Connect to Outlook” link in SharePoint 2013, I shared a workaround for an issue that a lot of people have experienced. Interestingly, I discovered that if you enable and disable the following three features in a certain order, you can actually make the Connect to Outlook link available at all times and there won’t be a need for the workaround.
- SharePoint Server Publishing Infrastructure at the Site Collection level.
- SharePoint Server Publishing at the site level.
For more detailed explanation of how, you can read my article that I just mentioned above.
How Can you Tell if MDS is Lying to You?
Another interesting thing I discovered is that if SharePoint Server Publishing is activated, which disables MDS, you can manually activate MDS and it will get activated. However, this can be very deceiving because in reality MDS is not activated. You can call it a fake activation. Why is it fake? Because the URL will not include _layouts/15/start.aspx#, which means MDS may tell you that it is activated but it is not really working. In this scenario, the only way to activate (i.e. enable) MDS is to disable SharePoint Server Publishing.
Disabling MDS Feature
I don’t recommend disabling MDS but if you must then here’s how you can disable it. Note that this is a site level feature that is not available at the site collection level.
WARNING! Disabling MDS will make your SharePoint site become very slow and therefore I do not recommend it. Only disable MDS if you have a justifiable business reason or a technical issue.
Copyright ©2014 Zubair Alexander. All rights reserved.