Cannot Delete Folder Because It Contains Checked Out Files: User-Safe Fix
🔍 WiseChecker

Cannot Delete Folder Because It Contains Checked Out Files: User-Safe Fix

You try to delete a folder in SharePoint or OneDrive but get the error: “Cannot delete folder because it contains checked out files.” This happens because one or more files inside the folder are locked by a user who has checked them out for editing. The folder cannot be removed until every file inside is checked back in. This article explains why this error occurs and provides a safe, step-by-step method to resolve it without losing data or requiring administrator access.

Key Takeaways: Delete a Folder Blocked by Checked Out Files

  • Site Contents > Library Settings: Use the “Manage files which have no checked in version” feature to discard checkouts on orphaned files.
  • Library Settings > Permissions and Management: The “Manage checked out files” link shows all checked out files and who holds the lock.
  • Site owner or library owner: Only users with Full Control or Design permissions can discard another user’s checkout.

ADVERTISEMENT

Why SharePoint Blocks Folder Deletion When Files Are Checked Out

SharePoint uses a check-out system to prevent two people from editing the same document at the same time. When a file is checked out, SharePoint treats it as locked. The system cannot delete a folder that contains any locked file because that would delete the file before it is saved back. This is a safety feature, not a bug.

The check-out lock is held by the user who checked out the file. If that user is still in the organization, they can check the file back in from their own account. If the user has left the company or the checkout is orphaned, the site owner or library owner must discard the checkout. Discarding a checkout reverts the file to its last saved version. Any changes made by the user who checked it out are lost.

How Check-Out Works in SharePoint Document Libraries

Check-out is a library setting that can be turned on or off by the library owner. When enabled, a user must check out a file before editing. The file shows a green arrow icon next to it in the library. Other users can view the file but cannot edit or delete it until it is checked back in. The check-out lock applies to the file and, by extension, to any parent folder that contains it.

Who Can Discard a Checked Out File

To discard a checkout, you need at least Design permissions on the site. Members of the Site Owners group have Full Control and can discard any checkout. Site Members with Edit permissions cannot discard another user’s checkout. If you are a site member and cannot delete the folder, contact a site owner to run the fix.

Steps to Delete a Folder Blocked by Checked Out Files

Follow these steps in order. Start with the easiest method. If the first method does not work, proceed to the next one.

Method 1: Ask the User Who Checked Out the File to Check It Back In

  1. Identify the checked out file
    Open the document library that contains the folder you cannot delete. Look for files with a green arrow icon. Hover over the icon to see the message “Checked Out To [username].” Note the username.
  2. Contact the user
    Send a message to the user whose name appears on the checked out file. Ask them to open the file and check it in. They can check in from the file’s context menu by selecting the ellipsis (…) > Check In.
  3. Verify the folder can be deleted
    After the user checks in the file, refresh the library page. Try to delete the folder again. If the error persists, repeat the identification step to see if another file is checked out.

Method 2: Use the Manage Checked Out Files Feature (Site Owner Required)

  1. Open Library Settings
    Navigate to the document library that contains the blocked folder. Click the gear icon in the top-right corner of the SharePoint page. Select Library settings from the menu.
  2. Find the Manage Checked Out Files link
    In the Library Settings page, scroll to the Permissions and Management section. Click the link labeled Manage files which have no checked in version. This link may also appear as Manage checked out files in some SharePoint versions.
  3. View the list of checked out files
    A page opens showing all files that are currently checked out in this library. Each row shows the file name, the user who checked it out, and a checkbox next to the file.
  4. Select the checked out file
    Find the file that is inside the folder you want to delete. Check the box next to that file.
  5. Discard the checkout
    Click the Discard Check Out button at the top of the list. A confirmation dialog appears. Click OK to confirm. The file is now checked back in. Any changes made by the user who checked it out are lost.
  6. Delete the folder
    Return to the document library. Select the folder and click Delete. The folder should now be removed without the error.

Method 3: Discard Checkout from the File’s Context Menu

  1. Locate the checked out file
    In the library, find the file with the green arrow icon. Select the file by clicking the circle next to its name.
  2. Open the context menu
    Click the ellipsis (…) that appears next to the file name.
  3. Choose Discard Check Out
    Scroll down the menu. Click Advanced if you do not see the option immediately. Then click Discard Check Out. Confirm the action.
  4. Delete the folder
    After discarding the checkout, return to the folder and delete it.

ADVERTISEMENT

If SharePoint Still Has Issues After the Main Fix

Checked out file does not appear in the Manage Checked Out Files list

This can happen if the file was checked out from a sync client or from a previous version of SharePoint. Try refreshing the library page. If the file still does not appear, use the Site Contents page instead. Navigate to Site Contents, locate the library, and click the three dots next to the library name. Select Settings and then Manage files which have no checked in version.

You get a permission error when trying to discard checkout

Only users with Full Control or Design permissions can discard another user’s checkout. If you see a permission error, you are not a site owner. Contact a site owner and ask them to run Method 2 or Method 3 for you.

The folder still cannot be deleted after discarding all checkouts

Another file in the folder may have been checked out after you discarded the first one. Refresh the library and repeat the identification step. Also check if the folder contains any subfolders with their own checked out files. You must clear checkouts in all subfolders before the parent folder can be deleted.

You want to prevent this problem in the future

Consider disabling the require check-out setting on the library if your team does not need it. Go to Library Settings > Versioning settings. Under Require Check Out, select No. Click OK. This allows users to edit files without checking them out. Existing checked out files will remain locked until they are checked in.

Require Check Out vs No Check Out: Key Differences

Item Require Check Out Enabled Require Check Out Disabled
File lock behavior File is locked until checked in File is not locked; multiple users can edit simultaneously
Folder deletion Blocked if any file is checked out Allowed at any time (file may be in use but not locked)
Version control Each check-in creates a new version Versions are created on save if versioning is turned on
Risk of lost changes Low, because only one user edits at a time Higher, because two users can overwrite each other’s changes

Now you can delete a folder that was blocked by checked out files. Start by asking the user who checked out the file to check it back in. If that is not possible, use the Manage Checked Out Files feature in Library Settings to discard the checkout. To prevent this issue in the future, consider turning off the require check-out setting in your library versioning settings. If you frequently encounter orphaned checkouts, set a site policy to automatically discard checkouts after a number of days.

ADVERTISEMENT