Inactive sites in SharePoint O365

Johana Guevara 25 Reputation points
2025-06-02T16:42:13.82+00:00

Is there a way to create some kind of policy or functionality so that sites in Sharepoint O365 with a downtime can be disabled or otherwise deleted?

Microsoft 365 and Office | SharePoint | Development
0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. Jade-T 1,560 Reputation points Microsoft External Staff Moderator
    2025-06-03T04:15:33.3133333+00:00

    Hi @Johana Guevara

    Thank you for your question. Based on your description, it seems you're looking to implement a policy to automatically manage (disable, close, or delete) inactive SharePoint Online sites. Below are three primary options, depending on the site type and your organization’s licensing: 

    1. Site Closure and Deletion Policies (Classic Sites - Manual Configuration) 

    This option allows you to manually configure automatic site closure and deletion for classic SharePoint sites

    • Go to the Site Settings of the classic site 
    • Under Site Collection Administration, select Site Collection Features 
    • Active the feature Site Policy 
    • Once activated, return to Site Settings > Site Policies 
    • Click Create to define a new policy by setting rules for automatic site closure, optionally enabling automatic deletion after closure, and specifying a notification period before deletion 
    • Save the policy, then go to Site Closure and Deletion (also under Site Settings) to apply the policy to the current site 

    Please note: This setup must be configured manually for each site collection and does not support bulk management. 

    You can find more detailed information and guidance on this option here: Use policies for site closure and deletion 

    2. Retention Policy via Microsoft Purview 

    If you're using Microsoft Purview, you can apply retention policies across SharePoint Online sites in a more centralized way. 

    • Go to the Microsoft Purview portal 
    • In the left navigation, go to Solution > Data Lifecycle Management > Policies > Retention policies 
    • Click + New retention policy 
    • Enter a name and description, then click Next 
    • Select Static as the policy type 
    • Enable SharePoint sites, then either apply to all sites or specify particular site URLs 
    • Set your retention period (e.g., 365 days) and choose what happens afterward (retain or delete content) 
    • Review and click Submit to publish the policy 

    Please note: Sites under a retention policy cannot be deleted until the retention period ends or the policy is removed. It may take up to 24 hours for changes to take effect. 

    For more detailed information, please refer to Microsoft’s official documentation: Learn about retention policies 

    3. Site Lifecycle Management (Modern Sites) 

    Microsoft offers a more advanced and automated option through Site Lifecycle Management. This lets you take actions—such as marking a site as read-only, archiving, or deleting—based on inactivity (e.g., no user activity for 90 days). For the most accurate and detailed guidance, please refer to the official Microsoft documentation here: Manage inactive sites using Site lifecycle management 

    If you need help determining which approach would be the best fit for your environment or would like assistance configuring any of the above, feel free to let me know—I'm happy to support you further. 


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.