File-Level Archiving in SharePoint: Complete Guide (Overview, Benefits, Prerequisites & Setup)
Contents
Introduction
Organizations using Microsoft SharePoint often face challenges in managing large volumes of data. Over time, document libraries grow significantly as files accumulate from completed projects, client deliverables, and operational activities.
While some of this data becomes inactive, it cannot always be deleted due to compliance, audit, or business requirements. Keeping all files in active storage increases costs and can affect performance.
File-Level Archiving is designed to address this problem by enabling organizations to move inactive files to a cost-effective storage tier while still retaining visibility and control.
How File-Level Archiving Works
The lifecycle of file-level archiving can be understood in the following steps:
- Identify files that are inactive or rarely accessed
- Archive selected files to a cold storage tier
- Maintain file visibility within the document library
- Restrict direct access to archived files
- Reactivate files when access is needed
This approach ensures that storage optimization happens without disrupting the user experience.
Benefits of File-Level Archiving
1. Cost Optimization
File-level archiving helps reduce storage costs by moving inactive files to a lower-cost storage tier.
- Active SharePoint storage is typically more expensive
- Archived files do not consume primary storage quota
- Organizations only pay for frequently accessed data
This is particularly useful for:
- Completed projects
- Historical records
- Large media files
2. Better Performance
Large document libraries can negatively impact system performance.
Archiving improves performance by:
- Reducing the volume of active files
- Improving search speed and accuracy
- Enhancing overall responsiveness of document libraries
Users benefit from faster navigation and a smoother experience.
3. Cleaner and Organized Structure
Over time, document libraries can become cluttered with outdated or irrelevant files.
File-level archiving helps:
- Separate active and inactive content
- Reduce clutter in document libraries
- Maintain a well-organized structure
This makes it easier for users to find relevant files quickly.
4. Data Retention and Compliance
Many organizations must retain data for regulatory and legal reasons.
File-level archiving ensures:
- Long-term preservation of important files
- Retention of metadata, permissions, and version history
- Compliance with audit and governance requirements
This allows organizations to meet compliance needs without overloading active storage.
5. On-Demand Access and Recovery
Archived files are not deleted and remain available when needed.
Key advantages include:
- Files remain visible in the document library
- Reactivation can be performed when access is required
- No permanent data loss
This provides flexibility while maintaining efficient storage usage.
Example Scenario:
A company completes multiple projects every year. Project files are rarely accessed after completion but must be retained for compliance.
Instead of keeping all files in active storage:
- Active projects remain in SharePoint
- Completed projects are archived
This reduces storage cost while keeping data accessible when needed.
Licensing Requirements
To use file-level archiving, the following components are required:
- SharePoint Online (Microsoft 365 subscription)
- Microsoft 365 Archive enabled with a pay-as-you-go model
Required permissions:
- Sites.Read.All for reading files
- Sites.ReadWrite.All for modifying files
Prerequisites for File-Level Archiving
Before implementing file-level archiving, ensure the following prerequisites are met:
- Azure Subscription A valid Azure subscription must be configured A resource group should be set up for pay-as-you-go billing
- Microsoft 365 Archive Enabled Enabled in Microsoft 365 Admin Center Path: Settings → Org Settings → Pay-as-you-go services → Archive
- SharePoint Online Management Shell Version must be 16.0.26714.12000 or later
- Administrative Permissions SharePoint Administrator or Global Administrator role required
Managing File-Level Archiving Using PowerShell
PowerShell is one of the most effective ways to manage SharePoint configurations at scale, especially when working with administrative features like file-level archiving.
Using PowerShell, administrators can:
- Enable archiving at the tenant level
- Configure archiving for specific SharePoint sites
- Automate setup across multiple environments
- Validate configuration settings
Below is a practical example demonstrating how to enable File-Level Archiving at both tenant and site levels.
Step-by-Step PowerShell Script
Import-Module Microsoft.Online.SharePoint.PowerShell -Force -ErrorAction Stop
$AdminUrl = "https://<tenant-name>-admin.sharepoint.com"
$SiteUrl = "https://<tenant-name>.sharepoint.com/sites/<site-name>"
# Connect
Write-Host "Connecting to Tenant Admin Center..." -ForegroundColor Yellow
Connect-SPOService -Url $AdminUrl
Write-Host "Connected!" -ForegroundColor Green
# Tenant level
Write-Host "Ensuring Tenant-level File Archive is enabled..." -ForegroundColor Yellow
Set-SPOTenant -AllowFileArchive $true
# Site level
Write-Host "Enabling File-Level Archiving for the site..." -ForegroundColor Yellow
try {
Set-SPOSite -Identity $SiteUrl -AllowFileArchive $true -ErrorAction Stop
Write-Host "Site-level setting applied successfully!" -ForegroundColor Green
}
catch {
Write-Host "Direct Set-SPOSite failed (common with Group sites)." -ForegroundColor Yellow
# Alternative: Get the site first, then set
$site = Get-SPOSite -Identity $SiteUrl -ErrorAction SilentlyContinue
if ($site) {
Set-SPOSite -Identity $site.Url -AllowFileArchive $true
Write-Host "Applied using retrieved site object." -ForegroundColor Green
} else {
Write-Host "cannot access the site via PowerShell." -ForegroundColor Red
}
}
# Show status
Write-Host ""
Write-Host "Current Tenant Setting:" -ForegroundColor Gray
Get-SPOTenant | Select-Object AllowFileArchive
Explanation of the Script
This script performs the complete setup required to enable file-level archiving.
1. Import Module
- Loads the SharePoint Online PowerShell module
- Ensures required commands are available
2. Connect to SharePoint Admin Center
- Uses Connect-SPOService to authenticate
- Required for executing tenant-level commands
3. Enable Tenant-Level Archiving
- Set-SPOTenant -AllowFileArchive $true
- This is mandatory before enabling it at the site level
4. Enable Site-Level Archiving
- Attempts to enable archiving directly on the site
- Uses error handling for better reliability
5. Fallback Logic (Important)
- Some sites (like Group-connected sites) may fail with direct command
- Script retrieves the site using Get-SPOSite and retries
6. Validation Step
- Retrieves tenant settings to confirm: File-Level Archiving is enabled
Key Takeaways
- Tenant-level configuration must be enabled first
- Site-level configuration is applied after tenant setup
- Error handling is important for real-world scenarios
- PowerShell provides flexibility for automation and bulk operations
Important Note
File-Level Archiving is currently in preview and may not be available in all tenants.Features, commands, and behavior may change as Microsoft continues rolling it out.
Conclusion
File-Level Archiving in SharePoint provides a structured and efficient approach to managing large volumes of data.
It enables organizations to:
- Reduce storage costs
- Improve system performance
- Maintain a clean and organized environment
- Meet compliance requirements
By moving inactive data to a lower-cost storage tier while keeping it accessible when needed, organizations can adopt a smarter and more scalable data management strategy.
As SharePoint continues to evolve, file-level archiving is expected to play a critical role in modern data lifecycle management.
About the author
Arnove Khatua
A, Khatua (27/10/2026) (4) Power Apps Modern Data Grid Just Got Serious About Big Data: Pagination, Row Virtualization & Delegation | LinkedIn