# Switch SharePoint Online Lists between Classic and Modern Experience

•
•
•
•
•
•

It’s been coming for a while.

Change is inevitable.

SharePoint Modern UI is here.

And, we’ve begun updating libraries and lists.

Per this link, https://techcommunity.microsoft.com/t5/SharePoint/Update-on-modern-list-tenant-opt-out-removal/td-p/469297, we changed the opt-out methods (from tenant-level to site-level).  One of the things that we noted is that you can use Enable-PnPFeature or Disable-PnPFeature to manage this.  In my experience, this hasn’t been working (as in, once you’re migrated, you can’t go back using this method).

I did, however, put together a script to help you accomplish it.

The big parameters:

Site – Use the -Site parameter to identify which site(s) you want to switch.  It’s an array, so add as many as you want.  You can also use AllSites to update all sites.  I’d recommend testing it out with a few individual sites first before taking the plunge.

Tenant – You need to tell it which tenant to use.

Experience – Again, not a mind reader.  You can use Classic or Modern here.

The examples:

# Example 1

Switch site https://tenant.sharepoint.com/sites/HR to the Classic library/list experience.



# Example 3

Switch all sites in tenant contoso to Modern library/list experience.

.\Set-SharePointSiteExperience.ps1 -Credential \$cred -AllSites -Tenant contoso -Experience Modern


You can get the Set-SharePointSiteExperience script here.