PowerShell to know site created date SharePoint 2013

InfoPath alternatives for form designing SharePoint

In this post we will discuss how to know site created date using PowerShell in SharePoint 2013. Using PowerShell we will be able to get the sites or sub sites created date.

Also read:
– SharePoint Server 2016 Installation Step by Step

– Document Sets in SharePoint 2013

– Discussion Board App missing in SharePoint 2013

Below is the PowerShell commands.

PowerShell command to get all site collections created date:

Add-PSSnapin “Microsoft.SharePoint.PowerShell”
Get-SPSite -Limit All | select Url, {$_.RootWeb.Created}

PowerShell command which will give Sites and Sub sites created in last 30 days:
Add-PSSnapin “Microsoft.SharePoint.PowerShell”
$Today = [DateTime]::Today
$Before30Days = $Today.AddDays(-30)
Get-SPSite -Limit All | where {$_.RootWeb.Created -ge $Before30Days -And $_.RootWeb.Created -lt $Today} |
select Url, {$_.RootWeb.Created}

PowerShell command which will return sites created Today:
Add-PSSnapin “Microsoft.SharePoint.PowerShell”
$Today = [DateTime]::Today
Get-SPSite -Limit All | where {$_.RootWeb.Created -eq $Today} |
select Url, {$_.RootWeb.Created}

PowerShell command which will return sites and sub sites created date for a Particular site collection:
Add-PSSnapin “Microsoft.SharePoint.PowerShell”
$site = get-spsite https://SiteCollectionURL/
$webs = $site.allwebs
foreach ($w in $webs){Write-Host $w.title ” is created on ” $w.created}

Hope this will be helpful.

Similar SharePoint 2013 Tutorials

About Bijay Kumar

I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SharePointSky.com

View all posts by Bijay Kumar →

Leave a Reply