How To Delete Multiple Cards In Trello

Trello is well-known for its effectiveness in managing projects by organizing tasks into boards. With a single view, Trello shows which tasks are being tackled, who is responsible for each, and the progress of each task. But what if you need to delete several cards simultaneously? Regrettably, Trello does not currently have a built-in capability for this. Fortunately, there is a workaround available.

Let’s walk through the steps on how to delete multiple cards in Trello.

Step 1: Install a Browser Extension

You need a browser extension that enables you to run JavaScript code in Trello’s environment. One such extension is Stylus for Chrome or Firefox. Once you’ve installed the extension, you can create a new script which will run on Trello’s website.

Step 2: Write the JavaScript Code

You’ll need to write a JavaScript code. The code below will select all the cards on your board and then delete them one by one.

var cards = document.getElementsByClassName('list-card');
for(var i = 0; i < cards.length; i++){
    var closeLink = cards[i].querySelector('a.js-close-card');
    if(closeLink){
        closeLink.click();
    }
    else{
        console.log('Could not find close link for card number ' + i);
    }
}

Step 3: Add To Stylus

Click on the Stylus extension icon and select ‘Manage’. Click on ‘New Style’ and paste your JavaScript code.

Step 4: Run The Code

Go back to your Trello board and refresh the page. Then, run the code by clicking on the Stylus extension icon and selecting the script you just added.

There you have it! This is one workaround to delete multiple cards on Trello. Remember that this method will delete all cards on your current board, so use it carefully.