Skip to content

Instantly share code, notes, and snippets.

@nishantrpai
Last active September 10, 2023 14:49
Show Gist options
  • Select an option

  • Save nishantrpai/05c0b64b9283c11475df907c0e47837e to your computer and use it in GitHub Desktop.

Select an option

Save nishantrpai/05c0b64b9283c11475df907c0e47837e to your computer and use it in GitHub Desktop.
Script to unfollow everyone on Twitter

Haven't tested this

Go to

https://twitter.com/*your username*/following

Right click, Inspect

Go to console

Paste this:

Array.from(document.querySelectorAll('[role="button"]')).filter(node => node.textContent == 'Following').map(btn => {
    btn.click();
    setTimeout(() => {
        document.querySelector('[data-testid="confirmationSheetConfirm"]').click()
    }, 500);
}) 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment