What happens when you delete a SharePoint Site

In this article you will learn what happens when you delete a SharePoint site, you will learn how to delete SharePoint site, how to delete a hub site in SharePoint, and how to permanently delete SharePoint site.

What happens when you delete a SharePoint Site

When you delete a SharePoint site, the site is moved to the Deleted Sites and is retained there for 93 days. That means, you have 93 days to restore that SharePoint site.

Also, when you delete a SharePoint site, everything that is associated with that site gets deleted. For example, the document libraries within the site, the files and folders within the document library, the site list and the list items, site settings, any sub-site that is created under that particular SharePoint site, and all the content of the sub-sites also get deleted. So if you are planning to delete a SharePoint site, you should always notify the site admins or the site owners of the sub-sites. So that they can move the site data to another location.

Moreover, when we delete a Team site, the associated Microsoft 365 Group also gets deleted. The Microsoft 365 Group that is associated to the Team site, is moved to the Deleted groups section and is retained there for 30 days.

Also, if you want to delete a hub site, you need to un-register the site as a Hub site. Only then you can delete a hub site.

How to delete SharePoint site

Delete SharePoint site from SharePoint Admin Center

To delete a SharePoint site in SharePoint Admin Center you need to be a Global Administrator or a SharePoint Administrator. You will go to SharePoint Admin Center, under Active Sites look for the site that you want to delete, select the site, and click Delete.

delete site

Now this site will move to the Deleted Sites section and will retain there for 93 days. And if you do not restore this site within 93 days, the site will be deleted permanently.

deleted sites

The above site that we just deleted, it was a Team Site. As we know a Team site has a Microsoft 365 Group associated. So if I delete a team site, the associated group should be deleted as well.

If we go to Entra ID > Groups > Deleted Groups, we can see the Microsoft 365 group that is associated with the team site that we just deleted.

entra id group

Likewise, if we delete a communication site from the active sites in SharePoint Admin Center, this site will go to the deleted sites and will be retained there for 93 days.

Also, if a site is deleted and is currently in deleted sites, no one will be able to access that particular site. If a user will try to access this site he will get 404 File not found error.

Note: Till the time the site is in deleted sites, we can not use the site name for another site. If we want to create a new SharePoint site with the same name, we need to delete the site permanently, and we need to wait for up to 24 hours. After 24 hours we can use this name for another SharePoint site.

Delete Communication Site from the site itself

There is one more way to delete a SharePoint site. You can delete a site from the site itself.

To delete a communication site from the site itself, you need to be the owner of the site, and you need to be the part of Site Admins group. If you want to check Site Owners of a communication site, you will click Site Access on the top right, expand Site Owners group.

site access
site owners

And if you want to check Site Admins group, you need to go to SharePoint Admin Center, under Active Sites select the site and click Membership. Under Site Admins you can see the list of site admins for that particular SharePoint site.

To delete a communication site from the site itself, click Settings > Site Information > Delete site, click Yes, and click Delete.

Likewise, if you want to delete a Team site from the site itself, you need to be the site owner. To delete a Team site, you will click Settings > Site Information > click Delete Site, click Yes, and click Delete.

Delete hub site in SharePoint

If you want to delete a hub site, you need to login to SharePoint Admin center. And you need to be a Global Administrator, or a SharePoint Administrator.

To delete a Hub Site, you need to first un-register the site as Hub Site. And as soon as you un-register a site as hub site, the Hub Navigation will be removed from the hub site.

To un-register a site as hub site you will go to SharePoint Admin Center, select the hub site, at the top you will click Hub, and click Unregister as Hub Site.

unresgister hub site

And now you can delete the site by selecting it and click Delete.

Remember, when you un-register a site as Hub Site, the associated sites will not be de-associated automatically. If you want to de-associate a site from the hub site, you will go to Settings > Site Information, and under Hub site association select None, and click Save.

Permanently delete SharePoint site

Before you delete a SharePoint site, you need to first understand what type of site you are going to delete. Because the way we follow to delete a site permanently will differ for both type of sites (Team Site and Communication Site).

If you want to delete a Communication site permanently, go to SharePoint Admin Center > Deleted sites, select the site that you want to delete, and click Permanently Delete.

delete site permanently 1

Now this site is deleted permanently, and all the content of this SharePoint site are also deleted.

But if we want to delete a Team site permanently, we can not delete it from SharePoint Admin Center. If we select a team site, the Permanently delete option will remain greyed out.

delete team site

So to delete a Team Site permanently, we need to use PowerShell. Open Windows PowerShell and run below commands:

PowerShell
Connect-SPOService -Url https://testdomain1234abc-admin.sharepoint.com/

Make sure to change the SharePoint Admin URL in above command.

Replace Team Site URL with the actual site URL and run below command:

PowerShell
Remove-SPODeletedSite -Identity "Team Site URL"

Now when you permanently delete a Team site that is connected to a Microsoft 365 group, this doesn’t delete the group permanently. The group will be retained within the Deleted groups section in Entra ID. If we want to delete this group permanently, select the group and click Delete Permanently.

Conclusion

In this article you learnt how to delete SharePoint sites, what happens when you delete SharePoint site, and how to permanently delete SharePoint sites.

You might like our other articles on SharePoint Online vs SharePoint Server, How to create sites in SharePoint Online, and Working with document libraries in SharePoint.

Join us on YouTube for the latest videos on the Cloud technology and join our Newsletter for the early access of the blogs and updates.

Happy Learning!!