If the site collection user accidentally deletes the top level site, the site collection also gets deleted. This will restrict the user to access the top level site and even sub sites from the site collection.
SharePoint Recycle bin feature doesn’t available for restore the deleted site collection.
Bu SharePoint 2013 provides the another option to restore the deleted site collection,
Whenever the site collection was deleted, the object is removed from SPSite and able to access using SPDeletedSite.To get the site collection back, we have to give Site Collection Id as input.
PowerShell command to Get the deleted Site Collection:
Get-SPDeletedSite < Site Collection server relative URL >
Get-SPDeletedSite –Identity < Site Collection ID >
PowerShell command to restore the deleted Site Collection:
Restore-SPDeletedSite -Identity < Site Collection ID >
June 8, 2016 at 5:58 AM
Thanks Shantha, you just saved my bacon! ;)
November 16, 2017 at 5:04 PM
Shantha, you totally saved my day! Thanks a lot!
June 6, 2019 at 7:02 PM
Shantha, you saved my website , and my job!