Here is a PowerShell script which can be used to iterate entire SharePoint Web Application and generate a report on it.
![SharePoint Management Shell SharePoint Management Shell](https://code2care.org/2015/powershell-iterate-and-get-all-sharepoint-sites-and-sub-sites/images/SharePoint Management Shell.png)
SharePoint Management Shell
Get all sites and subsites within SharePoint Web Application
Get-SPWebApplication http://sharepointsite |
Get-SPSite -Limit All | Get-SPWeb -Limit All |
Select Title, URL |
Export-CSV C:\SharePoint_Sites_Report.csv -NoTypeInformation
The Above code gets only the Site Title and Site URL in the report. You can add more parameters to the script to get more information like Size, Type, etc.
Note - Web Application is only available in SharePoint on-premise versions. SharePoint Online (Mictosoft Office 365) has only site collections.
Have Questions? Post them here!
More Posts related to SharePoint,
- SharePoint error - An exception occurred when trying to issue security token: This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms..
- PowerShell iterate and get all SharePoint sites and sub sites
- SharePoint Online: Editing session has ended Message
- How to Share Microsoft SharePoint Site with Users or Groups
- How to delete SharePoint Online List Item using REST API
- SharePoint List excel import - This table exceeds the maximum number of supported rows
- How to disable SharePoint subsite creation option for owners
- SharePoint 2010 August 2015 Update KB3055049 - Duplicate Document ID issue bug fixed
- SharePoint Server 2016 Preview installation error - This Product Key isn't a valid Microsoft Office 2016 Product Key. Check that you've entered it correctly.
- How to upload file programmatically to SharePoint Document Library using Server Object Model C# .Net
- Access URL for SharePoint Tenant Admin Center (Online Office 365)
- Error when deleting SharePoint Online folder or file
- How to extend retiring SharePoint 2010 Workflows and continue with Office 365
- How to generate client id and secret to register SharePoint App with OAuth
- How to delete SharePoint List Item programmatically using C#.Net
- How to retrieve all SharePoint Online List Items using Rest API
- [Solved] SharePoint Search Internal server error exception
- Create SharePoint Site Collection using PowerShell New-SPSite
- Fix SharePoint PowerShell error - The term Get-SPweb is not recognized as the name of a cmdlet function script file or operable program
- How to enable anonymous public access for SharePoint Online site collection, file, folder without login ?
- SharePoint Server 2016 installation System Hardware requirements
- How to create SharePoint Online List Item using REST API
- Changed AD user display name showing old name in SharePoint
- Recommended size and resolution for SharePoint Online Site logo
- Microsoft 365: How to Turn Off Delve in SharePoint Online for All Users
More Posts:
- Python: Access index/counter of a for loop iteration - Python
- How to turn off CR LF CRLF in Notepad++ - NotepadPlusPlus
- [fix] How to Show file extensions on all files on Mac - MacOS
- Where is .zshrc file located in macOS - MacOS
- appcompat_v7 errors after updates to API level 21 Material Theme - Android
- Bash Command to Check Disk Space - Bash
- Python: If Else Statements in One Single Line - Python
- [Solved] SharePoint System.IO.FileNotFoundException was unhandled - SharePoint