Skip to content

Instantly share code, notes, and snippets.

@cemerson
Last active September 12, 2023 11:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cemerson/e7b9b4886edf61501ba8e4235361286d to your computer and use it in GitHub Desktop.
Save cemerson/e7b9b4886edf61501ba8e4235361286d to your computer and use it in GitHub Desktop.
Bulk Delete Passwords from LastPass (DevTools script)

LASTPASS BULK Password Delete DevTools Hack

Version: 2023091201

Background

As of 9/2023 LastPass still apparently has no way to allow bulk deletion of passwords without clicking a checkbox on every single password. For many this is fine but for some like me this is very tedious. Frankly it's unacceptable that LastPass, who I pay $ to every year for Premium, still has no "Select All" option here.

Usage

In any case until/unless LastPass adds a "Select All" option, this script does that step for you. Usage:

  1. Go to your LastPass vault
  2. Search for the passwords you want to delete
  3. Run this script in DevTools console
  4. Review all items listed in the console that have now been "checked" for deletion
  5. Uncheck any passwords you DON'T want to delete
  6. Use the LastPass action dropdown to select DELETE
  7. Enjoy bulk deletion (without having to click EVERY single checkbox)
$('.tile.space-clickable').each(function(){
    if($(this).is(":visible")){
        console.log('... selecting [' + $('.vault-item-displayname p',$(this))[0].innerText + '] for deletion.');        
        $(this).trigger('click');         
    }    
});

Autistic?... probably. Saved me time?... 100%.

lastpassbulkdeletescript2023091201

Disclaimers:

  • WARNING: USE AT OWN RISK / All outcomes are your responsibility
  • This script may stop working if/when LastPass changes how their vault works and/or adds something similar themselves (here's hoping).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment