Transform the “SharePoint” Suite Bar Text into a Breadcrumb with PowerShell

March 11, 2013

Where is the breadcrumb in SharePoint 2013? There isn't one out-of-the-box, but this post helps you to get one back.

The out-of-the-box Seattle or Oslo master pages don't have a breadcrumb located in their HTML markup. That makes navigating from sub-sites to their parent site difficult, if you have not set a good global navigation structure.

This got me thinking about a solution to create a breadcrumb that could easily be added to the SharePoint sites.

The Idea

A few weeks ago I was playing with the SuiteBarBrandingElementHtml property to change the SharePoint text in the top left corner to my company name.

Note: there are already a few blog posts about this topic, so I will not explain this. Here is the blog post of Tobias Zimmergren on how you could change the text: Change the "SharePoint" text in the top left corner.

Changing the SharePoint text to your company name could be nice if you want some extra visibility, but still I find it a bit of unused space.

So this was the starting point of my idea, what if this could be replaced with a usable breadcrumb? That would certainly make navigating through sites a bit easier.

The Solution

The SuiteBarBrandingElementHtml element only allows html code to be added, because it will just show it as plain text on your page. My approach is to make use of some SharePoint ECMAScript to retrieve the parent sites of the current site you are on, and create a breadcrumb with this information.


First of all we need some JavaScript code:

As you can see it is not that difficult. The event listener is very important if MDS (Minimal Download Strategy) is enabled on your site, so this may not be removed (when it is removed, your breadcrumb will not render).

PowerShell Script

Applying this breadcrumb to your sites will be done via the web application SuiteBarBrandingElementHtml property. To do this you could use the following script:


Show LIbrary and Folders

Show LIbrary and Folders

Breadcrumb Sub-Sub-Site

Breadcrumb Sub-Sub-Site

Breadcrumb Sub-Site

Breadcrumb Sub-Site

Breadcrumb Top Site

Breadcrumb Top Site


Download the script here: Suite-Bar-Breadcrumb.ps1 - update

Revert to the default

If you want to revert to the default SharePoint text, it only requires to run the following script.



This solution won't work on SharePoint Foundation farms, on these farms the SocialRibbonControl feature is not present. A workaround could be to create your own solution (with an element file) to apply the control to the pages.

The element file looks like this:


Updated the script to make it work in IE8 and to fix a bug with checking folders.

Thank you Vicent and Max.


Added the revert to default situation script.


Updated the script based on the feedback from Maarten.