Export-Import subsite using PowerShell in SharePoint 2010
how to export SharePoint subsite? export subsite SharePoint 2013 PowerShell, Unlike SharePoint 2013, you'll have to create a subsite first and then import. Export-SPWeb cmdlet used to export a sub site, list or document library.
Open SharePoint 2013 Management Shell and run this command. Change Site URL and Path values accordingly.
Export-SPWeb "http://sharepoint.company.com/sites/Sales/US/" -Path "D:\backup\sales-us.cmp" -IncludeVersions All -includeusersecurity
To export a site, list or document library by using Central Administration:
You can also export a Subsite from SharePoint 2010/2013/2016 Central Administration via "Export a site or list" capability. Go to SharePoint Central Administration >> Backup and Restore >> Click on "Export a site or list" link under "Granular Backup" group.
Import subsite in SharePoint 2013 using PowerShell
Import-SPWeb PowerShell cmdlet used to import a sub site from backup.
Import-SPWeb "http://sharepoint.company.com/sites/Sales/US/" -Path "D:\backup\sales-us.cmp" -includeusersecurity -UpdateVersions overwriteWith these cmdlets, we can Export and Import a particular sub site, list or document library. You can also use Export-SPWeb & Import-SPWeb cmdlets to copy list with data between SharePoint Sites/Web Apps/or between different environments. E.g. Copy a SharePoint list from Dev to Staging server.
Please note, export-import is not as same as backup-restore. Certain artifacts will not be copied during export-import. Such as:
- Workflow association-data
- Audit logs
- Recycle bin items
- Created By, Modified By details, etc.
You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.