A Chrome extension for deleting your own Slack messages, using the Slack account you're already signed in to in the browser. No new Slack app, no token to copy, nothing for a workspace admin to approve.
Open any conversation, thread or DM in Slack, click the extension button, pick the messages you want gone, and it deletes them the same way Slack's own client does when you delete by hand (a chat.delete call), after you confirm.
The extension runs only on app.slack.com, inside the tab you've already signed in to. For each message you select it sends the same chat.delete request Slack's web client sends when you delete a message yourself, using the session that tab already has (read from Slack's own localStorage). The token is only ever sent back to your workspace's Slack API; it is never stored, logged or sent anywhere else. If the session can't be read, it falls back to clicking Slack's message menu → Delete message… → confirm.
- Only messages Slack shows as yours are listed, and only in the conversation you have open.
- Nothing is deleted until you select messages and confirm a warning dialog.
- Deletes are paced (about one per 1.2s) so Slack doesn't rate-limit you.
- If a message can't be removed (some workspaces block it), it's skipped and shown in the panel.
- Deletion uses Slack's real delete, so it cannot be undone.
The extension isn't on the Chrome Web Store; load it unpacked:
- Download the latest
slack-cleaner-vX.Y.Z.zipfrom Releases and unzip it. (Working from a clone instead? Runnpm install && npm run buildfirst, then use theextension/folder.) - Open
chrome://extensionsin Chrome (or any Chromium browser). - Turn on Developer mode (top right).
- Click Load unpacked and choose the unzipped
slack-cleanerfolder. - The Slack Cleaner button appears in your toolbar (pin it if you like).
Keep the folder somewhere permanent; Chrome loads the extension from it. To update, replace the folder with a newer release and click ↻ on the extension.
- Go to https://app.slack.com and open the channel, thread or DM you want to clean up.
- Click the Slack Cleaner toolbar button. A panel opens on the right.
- Pick messages tab: lists your messages that are currently on screen. Slack only loads messages as you scroll, so to reach older ones, scroll up in the conversation and click the rescan (↻) button. Tick the messages to delete (or the select-all box), optionally filter by text, then click Delete and confirm.
- Clear everything tab: deletes every message of yours in the conversation, starting at the newest and scrolling up to the top. Press Stop at any time.
- A progress bar shows how it's going; anything that couldn't be deleted is listed underneath.
- Work one conversation at a time. Switching conversations? Click Rescan.
- For a long history, scroll + Rescan in chunks rather than loading everything at once.
- The toolbar button toggles the panel open and closed.
- Only acts on messages Slack has rendered (what you've scrolled through), not your entire history at once.
- Slack's web layout changes occasionally; if scanning or deleting stops working, the selectors are all grouped at the top of
extension/slack-ui.jsfor a quick fix. - Some workspaces disable message deletion for members; those will report
cant_delete_message(orno_delete_optionin menu mode).
The extension is written in TypeScript (src/) and bundled with esbuild into the plain scripts Chrome loads from extension/. Requires Node 22.18+.
npm install
npm run build # src/*.ts -> extension/content.js, extension/background.js
npm run watch # rebuild on save; then click ↻ on the extension
npm run typecheck # tsc, strict
npm test # node:test runs the .ts tests directly
npm run package # build + dist/slack-cleaner-v<version>.zip for a releaseEvery push to main (including merged PRs) runs .github/workflows/release.yml: typecheck, tests, build, then it publishes a GitHub release with the zip if the version in extension/manifest.json doesn't have a release yet. So to ship, bump "version" in the manifest and push; pushes without a version bump just run the checks.
Tests cover the selection logic and the Slack DOM reading / delete / auto-clear flow against a simulated Slack page (jsdom), so they never touch a real workspace.
| File | What it does |
|---|---|
src/content.ts |
The in-page panel and the delete orchestration |
src/slack-ui.ts |
Reading Slack's DOM, chat.delete, auto-clear scrolling (all selectors here) |
src/selection.ts |
Pure selection/filter state (no DOM) |
src/background.ts |
Toolbar button → tells the tab to toggle the panel |
extension/manifest.json |
MV3 manifest; content script runs on app.slack.com |
extension/panel.css |
Panel styling (light and dark themes) |
extension/logo.svg |
Source for the logo; icon16/48/128.png are rendered from it |
scripts/build.mjs, scripts/package.mjs |
Build and release-zip scripts |