How to switch to modern experience in SharePoint Online List and Document Library

In this SharePoint tutorial, will discuss how we can switch from classic SharePoint Online experience to modern experience in SharePoint online list or document library or even site contents page.

Microsoft has already introduced modern experience in SharePoint Online list, document library, and in site pages. In the modern lists and libraries, there are lots of benefits like a modern look and feel, mobile devices enabled, etc.

But lots of organizations are still not willing to move to modern experience, rather they want to use the SharePoint online classic experience. Mostly because lots of lists and libraries have been customized using embedded javascript or jquery using script editor web part.

At the same time, lots of organizations are still using InfoPath forms in SharePoint online.

We will discuss in details, how we can switch from classic experience to modern experience in SharePoint online and vice versa. This we can do at various level.

Enable/Disable SharePoint online modern experience at the tenant level

We can enable or disable SharePoint online modern experience at the tenant level. Suppose if you do not want to use the new SharePoint online experience, then the best way is to disable at the tenant level.

Follow the below steps to enable or disable SharePoint online new experience.

Open SharePoint Online Admin center (-admin URL). And then click on settings like below:

modern experience sharepoint online
modern experience sharepoint online

And then in the settings page, you can see “SharePoint Lists and Libraries experience”. There you can choose as per the requirement. If you do not want to use the new experience, then you can choose the “Classic experience” radio button.

But if you want to use the new experience you can choose “New experience (auto-detect)”. Remember even if you choose New experience here at the tenant level, you still have the option to control at the site collection level, site level, and even a list and document library level.

sharepoint switch to new experience
sharepoint switch to new experience

Enable/Disable SharePoint modern experience at the site collection level or site level

We can Enable/Disable SharePoint modern experience at the site collection level or site level using PowerShell. There is no UI option to switch to a new experience or vice versa at the SharePoint Online site collection level or site level.

We can use PnP PowerShell to enable/disable modern UI at the site collection level or site level. There are two features involved in it.

  • Site Collection Level: We can use a site collection level feature whose ID is: E3540C7D-6BEA-403C-A224-1A12EAFEE4C4
  • Site Level: We can use a web scoped feature with ID 52E14B6F-B1BB-4969-B89B-C4FAA56745EF for the web level.

PowerShell to enable or disable modern experience at site collection level

We can use the below PowerShell command to enable or disable modern experience at the SharePoint Online site collection level.

$credential = Get-Credential
Connect-PnPOnline -Url https://[tenant].sharepoint.com/sites/siteurl -Credentials $credential

Enable-PnPFeature -Identity E3540C7D-6BEA-403C-A224-1A12EAFEE4C4 -Scope Site

Disable-PnPFeature -Identity E3540C7D-6BEA-403C-A224-1A12EAFEE4C4 -Scope Site

PowerShell to enable or disable modern experience at web level

We can use the below PowerShell command to enable or disable modern experience at the web level.

$credential = Get-Credential
Connect-PnPOnline -Url https://[tenant].sharepoint.com/sites/siteurl -Credentials $credential

Enable-PnPFeature -Identity 52E14B6F-B1BB-4969-B89B-C4FAA56745EF -Scope Web

Disable-PnPFeature -Identity 52E14B6F-B1BB-4969-B89B-C4FAA56745EF -Scope Web

SharePoint Online list or document library switch to a new experience

We can do settings at the list level or document library level to use new experience in SharePoint online. Open List or Library Settings page like below:

sharepoint list switch to modern view
sharepoint online document library new experience

Then in the list/library settings page, click on “Advanced settings” which is under the General settings section. This will open the Advanced settings page.

There search for “List experience” and you can see the below 3 options.

  • Default experience set by my administrator
  • New experience: Choose this option, if you want to use the new experience of the SharePoint online list or document library. If you choose this option, every time you open the list or library, you can see the modern UI for the particular list or library.
  • Classic experience: Choose this option if you want to use the SharePoint classic experience.
sharepoint modern experience
sharepoint modern experience

CSOM to enable or disable modern experience at site collection level

Below is the SharePoint CSOM code to enable or disable modern experience at the list level.

Here ListExperience has 3 values:

  • Auto: Will take the option set in at the tenant level
  • NewExperience: Will take the modern UI experience
  • ClassicExperience: Will set to classic experience of list or library

Below is the full code:

var list = context.Web.Lists.GetByTitle(title);
context.Load(list);
context.ExecuteQuery();
list.ListExperienceOptions = ListExperience.NewExperience;
list.Update();
context.ExecuteQuery();

Another efficient way to switch to modern UI experience in SharePoint online list or document library

If the new experience is enabled at the tenant level, then we can very easily switch to new modern UI, and also we can easily switch back to a classic experience in SharePoint online. We can do changes in the list, document library as well as site contents page also.

First open the document library, list or site contents page. There in the left side, you can see the option as “Return to classic SharePoint” if the library is open in modern UI or “Exit classic experience” if you are using classic UI.

You can see below fig since I am using classic UI site contents page, I can see the link “Exit classic experience” link. Just click on the link to switch to modern UI.

sharepoint site switch to new experience
sharepoint site switch to new experience

Once I click on the link, the site contents page will open in new UI, and you can see the link will appear as “Return to classic SharePoint”

sharepoint modern ui
SharePoint modern UI

If you are new to SharePoint Online modern experience, then you can read below SharePoint Online modern UI tutorials:

The same way you can achieve for list and document library also in SharePoint Online. I hope this article will be helpful to move from classic SharePoint Online list or document library to modern list and document library in SharePoint Online.

This way we can do SharePoint list switch to modern view.

>