Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). UI Patterns (SDC in Drupal UI) 2.0.18 Minor update available for module ui_patterns (2.0.18). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

File Delete (extras)

23,493 sites Security covered
View on drupal.org

This module allows administrators to delete files uploaded to Drupal sites, including those used by other users. It can change files to a temporary status for later cron deletion, offers immediate deletion options, and prevents deletion of files still in use.

Functionality landed in core 10.1 #2949017: There is no way to delete file entities of other users

The File Delete module adds the ability to easily delete files —both private and public— within Drupal administration.

It changes files from the "Permanent" status to the "Temporary" status. These files will be deleted by Drupal during its cron runs.

If a file is registered as being used somewhere, the Module will not allow it to be deleted.

Differences from core functionality

  • Built in safeguard that won't delete a file that has usage.
  • Option to delete form immediately, skipping core's file cleanup step.
  • Option to force delete a file, skipping the built-in access check.
  • Bulk plugins for doing mass deletions.

Other modules to consider

Media file delete - Media file delete gives content editors the option to delete the associated file when deleting a media entity.


Usage Notes

File is set to 'Temporary' but not getting deleted after a cron run

In Drupal, Temporary files generally kept for some time — default 6 hours — before being deleted.
You can configure this time in Administration » Configuration » Media » File System

Working with Drupal Media

If you added an image to the website as a Drupal Media entity, you will have to follow these steps.

  1. Important: Confirm that this Media is not being used in your site.
  2. Delete this Media entity in Administration » Content » Media
  3. Now you can delete the file in Administration » Content » Files

Why is this the case?
Drupal's File Usage system still needs some work. It does not correctly track all usages within Drupal. Most of the work related to this is being tracked in #2821423: Dealing with unexpected file deletion due to incorrect file usage
Specific to Drupal Media, the work is being tracked in #2835840: Track media usage and present it to the site builder (in the media library, media view, on media deletion confirmation, etc.)

Activity

Total releases
3
First release
Jan 2026
Latest release
4 weeks ago
Releases (12 mo)
3 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Release date
3.0.3 Stable Jun 17, 2026
3.0.2 Stable Jan 28, 2026
3.0.1 Stable Jan 5, 2026