ShareMaster V2 is in beta, a complete rebuild. See what is new and request access →
  1. Home
  2. Guides
  3. Bulk change library settings

How to Bulk Change SharePoint Library Settings Across Sites

SharePoint Online has no single screen that changes library settings across many sites. Microsoft's own tools each cover a slice. Library settings changes one library at a time. The admin centre's Version history limits page only shapes libraries created after you save it. Site-level PowerShell can push version limits into existing libraries, but nothing native sets Require Check Out, content approval or draft security in bulk. For those you either loop PnP PowerShell over every site, or use a tool that runs the loop for you.

Which route is right depends on which settings you need to change, so start there.

Which tool changes which library setting?

Setting Library settings page Admin centre org limit Set-SPOSite per site Set-PnPList loop
Versioning on or off, major or major and minor One library No No Yes
Major version count One library New libraries only New and existing Yes
Version time limit (automatic or days) One library New libraries only New and existing Yes
Require content approval One library No No Yes
Draft item security One library No No Yes
Require Check Out One library No No Yes

Microsoft says as much in its own documentation: the organisation-level limit handles document library version limits only, and major and minor versions, list versioning and content approval have to be configured on the individual library or list.

One library at a time: the Versioning settings page

Every setting in the table lives on a single page. In the library, open the gear menu, choose Library settings, follow More library settings, then select Versioning settings. You will find four groups there: content approval, document version history (with the count and time limits), draft item security, and Require Check Out.

For five libraries this is fine. For five hundred across eighty sites it is a week of clicking, and nobody can prove afterwards that every library got the same answer. That is the job the rest of this page is about.

Version limits: what the admin centre and Set-SPOSite really reach

Version limits are the one setting Microsoft does give you tenant and site controls for, and the scope of each is narrower than it looks.

  • Organisation level. In the SharePoint admin centre, go to Settings, then Version history limits, and pick Automatically or Manually. Manual takes between 100 and 50,000 major versions and an optional expiry. It applies to new libraries only, can take up to 24 hours to show up on them, and Microsoft states plainly that pushing the organisation limit into existing libraries is not supported.
  • Site level. PowerShell only. Set-SPOSite with -EnableAutoExpirationVersionTrim, -MajorVersionLimit and -ExpireVersionsAfterDays, plus -ApplyToExistingDocumentLibraries or -ApplyToNewDocumentLibraries, sets limits for one site. Existing libraries are updated asynchronously, which Microsoft says can run for up to 24 hours; track it with Get-SPOSiteVersionPolicyJobProgress.
  • Neither one trims. A new limit does not delete history that already exists. That takes a separate trim job, covered in trimming SharePoint version history.

Choosing the right count or expiry is its own decision, and setting a version limit per library walks through it. This page treats the version limit as one setting among six.

Bulk change library settings with PnP PowerShell

Set-PnPList exposes the rest: -EnableVersioning, -EnableMinorVersions, -MajorVersions, -MinorVersions, -EnableModeration (content approval), -DraftVersionVisibility (Reader, Author or Approver) and -ForceCheckout, and current versions add -EnableAutoExpirationVersionTrim and -ExpireVersionsAfterDays for time limits. Wrap it in two loops, one over sites and one over libraries:

$appId = "<your Entra ID app client id>"
Connect-PnPOnline -Url "https://contoso-admin.sharepoint.com" -Interactive -ClientId $appId
$targets = Get-PnPTenantSite | Where-Object { $_.Url -like "*/sites/proj-*" }

foreach ($site in $targets) {
    Connect-PnPOnline -Url $site.Url -Interactive -ClientId $appId
    $docLibs = Get-PnPList | Where-Object { $_.BaseTemplate -eq 101 -and -not $_.Hidden }
    foreach ($lib in $docLibs) {
        Set-PnPList -Identity $lib.Id -EnableModeration $false -ForceCheckout $true `
            -DraftVersionVisibility Author
        "{0} | {1}" -f $site.Url, $lib.Title
    }
}

Three things catch people out with this approach:

  1. You need your own app registration. The shared PnP Management Shell app was removed on 9 September 2024, so every script now signs in through an Entra ID app registered in your tenant (Register-PnPEntraIDApp creates one).
  2. Access is per site. The account has to reach every site in the loop. The SharePoint Administrator role lists the sites; it does not by itself let you open each one, so expect access-denied rows unless you add yourself as a site admin first and remember to remove yourself afterwards.
  3. Subsites are separate webs. The loop above visits the top site of each collection. Libraries inside subsites need a third loop.

Bulk change library settings in ShareMaster

ShareMaster's desktop app does the loop above as a form. The tool is called Settings Updater in the left-hand menu, and the tile you want is Document Library Settings Update. It lists the site collections in your tenant, you tick the ones to change, and it applies the same answers to every document library in each.

  1. Open Settings Updater and choose Document Library Settings Update. Sign in with an account that holds the SharePoint Administrator role, which the tile asks for.
  2. Tick the sites. The list covers every site collection except redirect sites, the OneDrive (My Site) host, and sites locked read-only or no access.
  3. For each settings group, either untick Don't Change and pick a value, or leave it ticked so that group is not touched.
  4. Select Update Settings. A confirmation reads "All document libraries within the selected sites will be updated." Confirm, and the progress dialog shows each site and library as it completes or fails.

What it changes

Group on the form Values you can set
Content Approval Require content approval for submitted items, on or off
Document Version History No versioning, Create major version, or Create major and minor (draft) versions
Version time limit No time limit, Automatic, or Manual with a number of days
Version count limit Number of major versions to keep, and how many major versions keep their drafts
Draft Item Security Any user who can read items, Only users who can edit items, or Only users who can approve items (and the author of the item)

Scope, stated precisely

  • Every library, not a pick list. It changes every list built on the document library template in each ticked site, which takes in Site Assets and Style Library as well as Documents. You cannot exclude one library inside a ticked site.
  • Top-level site only. Libraries in subsites are not visited.
  • Missing access is handled for you. If your account cannot open a ticked site, ShareMaster adds you as a site collection administrator for the run and removes you again when that site is done.
  • Version time limits need the newer version policy. Where a library does not expose it, the time limit is skipped and the other groups still apply.
  • No 100-version floor. The browser will not accept fewer than 100 major versions; ShareMaster writes the number you type. Microsoft advises against going under 100, so treat that as a reason to type carefully rather than a feature.
Note: Run it on one test site first, then open Versioning settings on two or three of its libraries and confirm each value before you tick the rest of the tenant. Turning on content approval in a library people are using changes how they save and who sees new files the same day, so tell site owners before you do it.

The same Settings Updater menu has a second tile, Site Share Settings Update, which sets the external sharing level, domain allow or block lists and default link permission on many sites at once. That is site-level sharing rather than library settings; for sharing links already handed out, see setting sharing link expiry.

In the V2 beta: the ShareMaster V2 beta has an Easy Settings tool that searches every tenant, site and list setting it can write, shows the current value in plain English and gives you the matching PowerShell. It works on one site and one list at a time, so it is the tool for checking and fixing a single library rather than sweeping a tenant.

Frequently Asked Questions

Does changing the organisation version history limit update existing libraries?

No. Microsoft documents that the organisation-level setting applies to libraries created after the change, can take up to 24 hours to reach them, and does not update existing libraries. For those, set limits per site with Set-SPOSite and -ApplyToExistingDocumentLibraries, or per library.

Can I turn on Require Check Out for every library at once?

Not from the SharePoint admin centre. Its version history controls cover version limits only, and Require Check Out is set library by library. Loop Set-PnPList -ForceCheckout over the libraries, as in the script above, and spot-check a few libraries afterwards.

Does lowering a version limit delete old versions straight away?

Changing a limit does not run a trim of the history that already exists. Clearing it needs a separate trim job or a version trimming tool. When SharePoint does delete versions over a library's limit, they bypass the recycle bin and cannot be restored from it, so decide on the number before you apply it everywhere.

Does ShareMaster change libraries in subsites?

No. Document Library Settings Update works on the top-level site of each site collection you tick. Libraries inside subsites keep their settings, so handle those separately.

What to do next

Before you standardise version limits, find out which libraries are carrying the most history so you know what the new limit will cost or save: a storage report by library shows where it sits.

Try ShareMaster free for 14 days