Understanding SharePoint Online Document Library Size and Item Limits
Question details
The user wants to know the maximum capacity and size limits of a SharePoint Online document library, especially when managing a large volume of files integrated with Dynamics 365.

- Product
- SharePoint Online
- Device & OS
- not provided
- Scenario
- Managing, migrating, or integrating a large-scale SharePoint Online document library without encountering performance degradation or sync errors.
- Observed behavior
- The library can hold up to 30 million items, but exceeding the 5,000-item view threshold causes performance issues, alerts, and recurring failures during third-party site migrations.
Before modifying library settings, verify that you have Site Owner or Administrator permissions to create indexed columns and edit public list views.
Optimize Large Libraries by Indexing Columns and Filtering Views
Create indexed columns and apply filtered views to bypass the 5,000-item list-view threshold without reducing the actual number of files in the library.
While a single SharePoint document library can technically store up to 30 million files, the system enforces a strict 5,000-item list-view threshold. If a specific view attempts to load more than 5,000 items at once, SharePoint blocks the query to prevent server performance degradation. Adding an index to a column allows SharePoint to quickly filter the data before hitting the threshold.
Open your SharePoint document library in a web browser. Click the Gear icon (Settings) in the top-right corner of the screen, then select 'Library settings', followed by 'More library settings'.
Scroll down to the 'Columns' section and click on 'Indexed columns'. Click 'Create a new index', select a column you frequently use for filtering (such as 'Created' or 'Document Status'), and click 'OK'.
Return to your document library. Click the view dropdown menu in the command bar (usually labeled 'All Documents') and select 'Edit current view'.
Scroll down to the 'Filter' section in the view settings. Select 'Show items only when the following is true', choose the column you just indexed, and set a condition (e.g., 'Created is greater than [Today]-30') so that the view returns fewer than 5,000 items. Click 'OK' to save.

Organize Files Using a Hierarchical Folder Structure
Distribute your files into nested folders to reduce the item count at the root level and prevent hitting the threshold during migrations or syncs.
Manage and Edit Your Documents Locally with WPS Office
If SharePoint's strict list-view thresholds and complex online syncing limits disrupt your workflow, consider handling your documents locally with WPS Office. It is a powerful, lightweight, and highly compatible alternative to Microsoft Office that lets you manage your files without worrying about cloud library constraints.
- 1. Download the Installer: Visit the official WPS Office website and download the free installer for your operating system.
- 2. Install WPS Office: Run the downloaded file and follow the straightforward on-screen instructions to complete the installation.
- 3. Open Your Documents: Launch WPS Office and easily open, edit, and save the documents you've exported from SharePoint without any format loss.

Frequently Asked Questions
Is there a maximum storage size limit for a single SharePoint library?
There is no separate storage limit for an individual document library. However, the library is bound by the total storage limit of the site collection it resides in, which can be up to 25 TB depending on your Microsoft 365 tenant settings.
Why do I receive errors when my SharePoint library exceeds 5,000 items?
SharePoint enforces a 5,000-item list-view threshold to prevent SQL server database locks and ensure optimal server performance across the platform. If a single view attempts to fetch more than 5,000 items simultaneously, SharePoint blocks the request. Using filtered views based on indexed columns is the recommended workaround.
Can a single SharePoint document library hold 30 million files?
Yes, a library can physically contain up to 30 million files and folders. However, successfully managing a library of this scale requires strict data governance, properly nested folder structures, and heavily optimized, filtered views to remain functional.
Does exceeding the library item threshold affect third-party migration tools?
Yes. If your library has tens of thousands of items without proper folder structures, third-party migration tools (like BitTitan) may repeatedly fail or time out because they hit the list-view threshold when trying to query the contents of the root directory.




