Deleting Twitter favourites/likes with one click

I have been in the habit for years now, to delete my Twitter favourites or likes, because I 'heart' them for lots of reasons, most of which have nothing to do with actually liking the tweet. I have been in the habit of bookmarking tweets with the likes since forever, because I may use the tweet in a future article or presentation. But I can also use the like as a simple "saw this tweet" at the end of a long twitter thread, and just as your general "I actually liked this," as well as just accidentally liking tweets as I scroll by with my stupid thumb. Or rather, knuckle, if you saw the length of my nails you'd know I'm a knuckle-phone operator.

No matter what people may assume about my likes, it's a privacy issue, anyone can see tweets that you 'liked', which reveals a lot about the accounts that you follow and interact with. So, I delete them, as often as I can. Today I was reminded to do so when I saw that a Center party politician in Sweden decided to unfollow a news organisation because they had liked a Trump tweet. The news organisation Finwire news coincidentally reports on a lot of things that Trump tweets as it affects financial sectors.

This is a little javascript that works well with the new Twitter layout to delete every tweet you liked (that can be seen). If your account is as old as mine is, you may have a remnant number of likes registered in your count, but no liked tweets can be seen. This is due to Twitter API limitations, and more robust methods can get rid of those if you want to, for example the paid version of Twitter Archive Eraser can delete those, as well as all of your old tweets well past the 3200 limit. 

This little snipped is free to use though and works just fine.

Simply go to the likes page of your account (when you are logged in to Twitter with your web browser it is at twitter.com/youname/likes), open the developer window for javascript, and copy-paste this into the console.

 

setInterval(() => { for (const d of document.querySelectorAll('div[data-testid="unlike"]')) { d.click() } window.scrollTo(0, document.body.scrollHeight) }, 1000)

 

Leave the window open for a bit and go make a cup of tea, once it has run its course you will have no liked tweets. Fresh start. Now people can judge you for everything that you retweet instead.


Dabitch

Dabitch

Founder of adland®, sweetheart hell-raiser, tired of writing bios.