SharePoint Online: How to Enable Tree View?
Requirement: Enable the Tree view in SharePoint Online.
How to Enable Tree View in SharePoint Online?
SharePoint Online is a flexible and user-friendly platform that helps you collaborate with colleagues, store documents, and share information. The Tree View is used in the Quick Launch area to list all sub-sites, libraries, and lists within the current site collection. It provides the ability to expand any listed subsites to view the lists, libraries, and folders easier. The tree view is handy when you have a lot of files and folders to work with, and it provides a great way to navigate through lengthy SharePoint document libraries and help managing content efficiently. This blog post will show you how to activate the tree view in SharePoint Online.
To enable the tree view in SharePoint Online, follow these steps:
- Navigate to the SharePoint site in the browser that you want to enable the tree view >> From the SharePoint Online home page, Click on Settings and choose Site Settings from the menu.
- On the Site Settings page, click on “Navigation Elements” under the “Look and Feel” section. (URL Shortcut: /_layouts/navoptions.aspx)
- In the “Enable Tree View” section, check the “Enable Tree View” option to enable the tree view.
- Click on OK to save your changes.
Enabling the Tree view is a simple way to make navigating large lists and libraries much easier. Tree view allows you to expand and collapse items in the list or library, so you can quickly find the item you’re looking for. You’ll be able to expand and collapse items using the “Expand” and “Collapse” symbols on each item. Here is what the document library tree view looks like on the SharePoint Online site.
Make sure your library’s list experience is set to “Classic” under Library settings >> Advanced Settings >> List experience. (This works for modern sites as well). We also have the Metadata navigation feature through Metadata navigation settings under the document library settings. However, this feature also works and shows site hierarchy only on classic experience.
PowerShell to Enable Tree View in SharePoint Online
By default, SharePoint lists and libraries are displayed in flat view, which can be tedious to scroll through if there are a lot of items. Let’s enable Tree view using PowerShell:
#Parameters
$SiteURL = "https://crescent.sharepoint.com/sites/Retail"
Try {
#Connect to the Site
Connect-PnPOnline -Url $SiteURL -Interactive
#Get the Web
$Web = Get-PnPWeb -Includes TreeViewEnabled
#Enable Tree View
$Web.TreeViewEnabled = $True
$Web.Update()
Invoke-PnPQuery
Write-Host "Enabled the Tree View!" -f Green
}
Catch {
Write-host "Error:"$_.Exception.Message
}
Now, refresh the page, and you should see the tree view below the Quick Launch on the SharePoint Online site.
And there you have it – with just a few configuration steps, SharePoint site administrators can enable the treeview feature for site navigation. This useful interface option improves information architecture through clear content hierarchy and easy collapse/expand of folders.
Is there a way to export my site tree view onto an Excel document or another external file?