Outlook Bulk Delete by Date Range
Free to download on every platform. Comes pre-installed on BotFone, BotPad and BotFlip — with extra free apps included.
About this app
WHAT IT DOES
This userscript helps you clean up your Outlook inbox by bulk-deleting emails within a specific date range. It scans Outlook inbox or email list pages for email threads, extracts dates from email metadata or page text, and allows you to select a date range to bulk delete all emails within that range. It shows the subject, sender, and date of each thread, filters by date range, and maintains a list of already deleted threads to avoid duplicates. It exports the list of selected threads and provides a confirmation step before taking action. The script simulates the delete action by moving emails to the Deleted Items folder or marking them for deletion.
WHERE IT RUNS
The script works on Outlook inbox pages, email list pages, and any webpage with email thread information and dates. It runs entirely within your browser, reading only the visible content of the current page. It does not track your browsing history, access other tabs, or send any data externally. All thread data and delete history are stored locally.
HOW TO USE
After installation, open the panel by clicking the tool's icon in the BotGentz sidebar. Enter a start date and end date in YYYY-MM-DD format. Click "Scan for threads" to extract email threads from the current page. The panel displays a list of threads with checkboxes, showing the subject, sender, and date. Only threads within the date range are shown. Select the threads you want to delete—use "Select All" to choose all. Click "Delete Selected (Track)" to mark them as deleted and add them to your history. Click "Export Selected" to download a text file with the selected thread information. Use "Clear History" to reset the delete history.
THE TECHNICAL MECHANISM
This script uses DOM traversal and text pattern matching to extract email thread information and dates from Outlook pages. It scans for thread elements using class names like "thread", "email", "message", "zA", "zE", and "yW". It extracts the subject (looking for "Subject:" patterns), sender (looking for "From:" patterns and email addresses), and dates using multiple date format patterns (MM/DD/YYYY, YYYY-MM-DD, named month formats, and day-month formats). It deduplicates threads by subject, sender, and date. The script stores the delete history in GM_setValue so you don't see already-deleted threads in future scans. The export function creates a plain text file with the selected thread keys (subject|sender|date). All operations are client-side and do not send any data externally.
THE PANEL
The panel is draggable anywhere on the screen and remembers its position between sessions. It can be collapsed to a small floating bubble to minimize distraction, and expanded again with a single click. The panel's width can be adjusted, and pressing the Escape key closes it instantly. All settings—date range, delete history, and auto-scan preference—are persisted locally using GM_setValue, so your data remains intact across page reloads and browser restarts.
PLEASE NOTE
This userscript requires the free BotGentz extension to function. The script extracts threads and dates from page text—it may not capture all dates correctly. Review and adjust extracted data as needed. The script helps you track which threads you've deleted—it does not actually delete emails from your Outlook account. You'll need to manually delete them in Outlook. The extraction relies on the current text patterns on the page—if Outlook updates its UI, the script may need to be updated. The script does not access your Outlook account or API; it only reads what is visible on the page. No data from your browsing is stored or transmitted anywhere—all processing occurs entirely in your browser.