do-not-repeat-it-in-production_demotivator (1)

When we accidentally delete some web, it could be found in Central Administration’s Recycle Bin(http://server/_layouts/15/AdminRecycleBin.aspx?View=2)

But if we delete Site Collection(that contains all these webs)


– in Recycle Bin there will be nothing. You can simply delete site collection like any other web, and there is no one way to restore it from Web Interface :)

There is no preview check like, by example, on GitHub:


As usually – SharePoint generates a problem for Us, and then proposes a solution to resolve this problem:

deleted site collection remains in object, which we can access by Get-SPDeletedSite:


Knowing its SiteId, we can restore site collection using Restore-SPDeletedSite:

Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue
Restore-SPDeletedSite -Identity 8be8d8d4-a8c5-4eda-91cd-0c27b79a050d

p.s.: And if You really want to kill Your site collection – SharePoint can help You here too – welcome to other powershell commandlet Remove-SPSite, which could be undone at all :)

p.p.s.: Be happy, Make backups and Plan Your governance and security in SharePoint :)

Click below to expand comments form..