When Ronson wrote about the injustice of Justine Saccos trial by Twitter, he found that he too became a target of an internet witch hunt. How did we become unpaid shaming interns for companies that dont care about us?

In December 2013 a PR woman called Justine Sacco tweeted to her 170 Twitter followers: Going to Africa. Hope I dont get Aids. Just kidding. Im white! The joke was intended to mock her own bubble of privilege, but while she slept on the plane Twitter took control of her life and dismantled it. She became the worldwide number one trending topic that night: We are about to watch this Justine Sacco bitch get fired, in real time, before she even knows shes being fired, and Everyone go report this cunt @justinesacco, and so on, for a total of 100,000 tweets. Justine was fired, her reputation mangled. I recounted her story in my book, So Youve Been Publicly Shamed. The chapter was excerpted in the New York Times Magazine. Ive been keeping a diary of what happened next.

Condemnation began hesitantly at first, a little uncertain, like a consensus waiting to form: The article did nothing but bring her back into the spotlight when wed all moved on, somebody tweeted. Her dad is a billionaire, someone replied. Im not too worried about her. (Her father isnt a billionaire. He sells carpets.) That tweet didnt ruin her life, someone added. Justine Sacco has a new job. Give me a break already.

After a year, I thought when I read that one. She got a new job after a year. Nice people like us had effectively sentenced Justine Sacco to a years punishment for the crime of some poor phraseology in a tweet as if some clunky wording had been a clue to her secret inner evil. The fact that she had managed to doggedly pull things back together after a year was now being used as evidence that the shaming had been no big deal from the start.

I remembered a time I was on a beach in Scotland and a flock of terns singled me out. They circled above me for a while, and then began to dive bomb, pecking at my head. This early, tentative disapproval felt like the terns circling. And then the dive-bombing began: After reading that excerpt from his book. I think its safe to say @jonronson is a fucking racist.

A group of Chelsea fans were filmed on the Paris Metro pushing a black man off the train and chanting: Were racist, were racist, and thats the way we like it. It was a shocking, awful video.

Maybe Jon Ronson will cape up for em, somebody wrote.

An opinion was beginning to form, and feed off itself, that I had written an attack on social justice, a defence of white privilege. In coming out against online shaming I was silencing marginalised voices because online shaming is the only recourse of the marginalised, whereas the world automatically allows people like Justine to succeed. But I just couldnt see how Justines shaming made anything better, given that her joke was intended to mock racism. What happened to Justine struck me as just another terrible thing happening in the world.

I decided to try to encourage those people to read the book, and so I tweeted: By the way, the Justine Sacco story in the New York Times isnt a stand-alone article. Its an extract from a book.

Oh, now Ronsons saying its an extract from a book, someone wrote.

What did that mean? It was always an extract from a book. Did he think I ran home and quickly wrote a book? But anything I said in that moment, I realised, would just be more evidence for the prosecution, and so I went back to being silent.

Why isnt Jon Ronson replying to any of us? someone tweeted.

Because Jon Ronson only replies to men, someone replied.

I liked it when people went for me in ridiculous ways, because when I recounted those comments to other people they made me look good.

Still, I didnt regret writing Justines story. I was basically being told, Its fine to write about those wronged people, but dont write about that wronged person because it makes us look bad. But a wronged person is a wronged person, even when they are an unfashionable wronged person.

I wrote about Justine not because I identified with her, although I did, but because I identified with the people who tore her apart. I consider myself a social justice person. It was my people, abusing our power.

I emailed Justine: Im getting an idea of what it was like to be you.

Im really sorry if youre getting death threats, she emailed back. No one should receive threats or words of violence at all.

Well nobodys threatening to actually kill me, I replied. (As is often the case with shamings, the range of insults levelled against Justine, a woman, had been far broader than those levelled against me, a man.)

A train crashed in Philadelphia. Passenger cars were ripped apart. Eight people died and 200 more were hospitalised. A survivor emerged from the wreckage and tweeted: Thanks a lot for derailing my train. Can I please get my violin back from the 2nd car of the train?

Twitter suddenly felt uncaring, intimidating, even dangerous … Ronson. Photograph: Christopher Lane for the Guardian

In the early days, Twitter was a place of curiosity and empathy. Back then, people might have responded to this woman: Are you OK? or What was it like? But thats not how Twitter and Facebook responded in 2015. Instead, it was: Some spoiled asshole is whining about her violin being on that Amtrak that derailed. People died on that train and |I hope the violin is crushed and I hope someone picks it up and smacks it against the train and Fuck that little bitch and her god-damned violin. I would slap the fuckin taste out of her mouth if she was in reach and then after she deleted her Twitter account Too bad shes a coward and deleted her account, how will her violin ever be returned? and I hope you get your violin back from under the bleeding people. Good luck! and I hope it is destroyed and Your violin can be replaced. The DEAD are gone forever and Self-absorbed cunt and I wont be cutting her any slack. What a sickening skank. I hope her life is exactly what a nasty bitch deserves and 8 passengers dead, but she lives. No justice in the world.

Like Justine, she was being shamed because she was perceived to have misused her privilege. And of course the misuse of privilege is a much better thing to get people for than the things we used to get people for, like having children out of wedlock. But a great number of people who hadnt just been in a train crash were now accusing a woman who had just been in a train crash of being privileged. The phrase misuse of privilege was becoming a free pass to tear apart pretty much anybody we chose to. It was becoming a devalued term, and was making us lose our capacity for empathy and for distinguishing between serious and unserious transgressions.

I visited a TV studio in New York to film a video about the book. There was a doctor on before me, filming her own video.

Whats your book about? she asked me.

Online shaming, I replied.

Oh, did you read that piece in the New York Times? she asked.

I wrote it, I replied.

Oh you must be so happy! she said.

Actually Im not, I replied.

Why not? she asked.

Because theres a backlash, with people calling me a racist, I said.

So what do you want? she said.

I paused.

Xanax? I said.

She got out her pad and wrote me a prescription for 60 Xanax. After that I was no longer anxious. But I felt groggy. I had to weigh up whether to feel groggy or anxious. Later, I mentioned this to the comedian Joe Rogan. Welcome to America, he replied. Thats our dilemma. Groggy or anxious.

I was getting misdefined by some people as a racist, and as a consequence I was starting to misdefine myself as someone who felt the need to leap into pretty much any ambiguous shaming and take a counterintuitive position. It was becoming unseemly. On 12 June I read in the Guardian about Rachel Dolezal, the Washington State civil rights activist who had faked being black.

What an extraordinary story, I thought. So mysterious and complicated. What led her to fake being black? Maybe she has a mental illness. Or maybe she doesnt. Maybe she feels about colour the way some transgender people feel about gender. Or maybe she doesnt feel that way. I had a thousand questions. A journalists favourite question is Why? Why? opens doors into new worlds.

I wonder what Twitter is making of it? I thought. And so I went on Twitter.

#RachelDolezal you can APPRECIATE a culture, without APPROPRIATING it. The fact you cant grasp that is one reason youre a racist idiot and #RachelDolezal has been living in Black-Face her whole life, seems cut & dry racist to me and We should apply a super-strength relaxer onto #RachelDolezal head & not wash it out. Allow it to burn through her skull & racist brain and Make no mistake: #RachelDolezal is a self absorbed, psychotic & sociopathic racist.

On social media wed had the chance to do everything better, but instead of curiosity we were constantly lurching towards instant cold judgment. Maybe Dolezal was everything Twitter assumed she was, but what was wrong with a bit of waiting for evidence? Maybe she was reading all the tweets and thinking about killing herself. (That was possible. Three weeks earlier an Israeli government clerk called Ariel Runis had killed himself in similar circumstances.)

I was tired of us forever making damaged people our playthings. And so I tweeted: Feeling incredibly sorry for #RachelDolezal and hope shes okay. The world knows very little about her, her motives.

I went to dinner. I chatted away with people at the table. Everyone was nice. I went on Twitter. Someone was calling me a white supremacist. I went back to the dinner conversation. It was nice. I went back on Twitter. Somebody, pretending to be me, had written: Dylann Roof is good. Dylann Roof was the racist who murdered nine African Americans in Charleston, South Carolina.

Someone told me I had no right to weigh into Dolezals story because, being white, it wasnt my story. He added that, unlike her, he had no choice in being black or white. As a black man he was racially profiled every time he walked down the street. He was genuinely angry with me for chipping in the way I had. I explained my reasons that after 30 years of writing about complicated, spiralling people I had opinions on how to consider them. But he was right. In all the hardening of positions Id become a caricature.

I complained to Twitter about the man who, pretending to be me, commended the Charleston racist murderer. Twitter responded: We have determined that its not in violation of Twitters impersonation policy. I felt a flash of rage. Every time an online shaming occurred Twitter and Google made money. Whereas those of us doing the actual shaming? We got nothing. Twitter suddenly felt uncaring, intimidating, even dangerous. We were unpaid shaming interns for a company that didnt care about us. I quit Twitter.

The world outside Twitter was great. I read books. I reconnected with people I knew from real life and met them for drinks in person. Then I drifted back on to Twitter.

Someone told me I would have avoided much of the criticism had I ended my book with a set of rules outlining when shamings were and werent OK. It hadnt crossed my mind to do that because it sounded like the kind of thing lifestyle coaches do. And, anyway, it seemed obvious. During 2014 and 2015 videos were surfacing of police brutality against people of colour. People were dying: Eric Garner and Michael Brown and Sandra Bland. In McKinney, Texas a police officer was filmed pulling his gun on a group of unarmed black teenagers at a pool party. He violently wrestled a girl to the ground, using his bodyweight to pin her down. She was wearing a bikini. I want to call my mom, she screamed, terrified.

It didnt need saying but maybe it did that using social media to distribute those videos was a world away from the Justine Sacco witchhunt. One was powerful and important, a new civil rights battlefield. The other was a nasty imitation. Given that we are the ones with the power, it is up to us to recognise the difference. The great thing about social media was how it gave a voice to voiceless people. We are now turning it into a surveillance society where the smartest way to survive is to go back to being voiceless.

The new paperback edition of So Youve Been Publicly Shamed by Jon Ronson is published by Picador at £8.99 on 31 December 2015. To order a copy for £7.19 go to bookshop.theguardian.com or call 0330 333 6846. Free UK p&p over £10, online orders only. Phone orders min p&p of £1.99.

Read more: www.theguardian.com