When I was invited to discuss atheism on “The O’Reilly Factor” four years ago, I initially wanted to turn it down. However, I ultimately realized it was a chance to show Fox News viewers a different side of atheism on a network where atheists are usually talked about rather than with.

It was December, so former Fox News host Bill O’Reilly attempted to paint atheists as bitter anti-religion Grinches on a mission to take Christmas away. I pushed back, emphasizing the value of the separation of church and state as well as atheists’ contributions to the public conversation on religion and ethics.

In an environment that rewards anger and sound bites, I attempted to humanize my community — one of the most negatively viewed in the country. Afterward, strangers from around the country messaged me to say the conversation helped them rethink their views on atheists.

But the chatter online took a different, but sadly familiar, tone.

A number of prominent atheist bloggers criticized my interview, saying I was awful and suggesting I was allying with O’Reilly. The comments were worse. Anonymous posters ridiculed me, saying I should decline future television invitations because I was too “effeminate,” my physical appearance made atheists seem “like freaks” and my “obvious homosexuality” made me an ineffectual voice for atheists.

I had started an atheist blog almost a decade ago to explore the role of the nonreligious in interfaith dialogue. I went on to write for bigger platforms and appear on CNN and MSNBC to defend atheists against our detractors. But even as I spoke up for atheists, a subset of the community attacked me and my work, including a book I wrote about atheism and interfaith activism. There were some legitimate critiques, and I’m grateful for how they challenged me and helped me rethink some of my ideas, but others were petty and vindictive.

One of my most frequent online critics — who posted defamatory and false accusations about me — taunted me in ways that reminded me of the playground bullies who attacked me for being queer. He and his supporters frequently called me wimpy, weak, feeble and pearl-clutching, and characterized my work as “tinkerbellism.” When we faced off in a debate sponsored by humanist groups in Australia, he (hilariously) told me that I “sucked.”

Other bloggers went further, writing posts attacking my personal life; one went after my mother directly. (The author of that post later apologized, thankfully.) While most posts and comments were merely cruel insults, I was also threatened with violence and received death threats.

I was far from the only one targeted. A lot of online discourse can turn vitriolic, but writing on atheism seems particularly so. A study on Reddit found that its atheist forum, probably the largest collection of atheists on the Internet, was the third most toxic and bigoted on the entire site.

I’ve watched as many of the activists and writers I respect most in atheism — especially women and people of color — have left the movement, each expressing (privately, if not publicly) that the state of the discourse among atheists was one of the primary reasons they were leaving.

Beyond the nastiness directed at me, I was even more frustrated with the ways the atheist movement, especially online, has resisted efforts to address racism, sexism and xenophobia among our own. I’ve been researching the intersection of atheism and the “alt-right” this year, and things don’t seem to have improved much in the years since I stepped back.

I also felt a gnawing sense of smallness during my years as an atheist writer, exhausted with having to represent a singular identity. When I appeared on “The O’Reilly Factor,” the chyron that appeared below me read, “CHRIS STEDMAN, ATHEIST.” My friends and I had a good laugh about it, but it represented a bigger problem: to be understood as an atheist, I was often asked to reduce myself to just that.

This is a broad problem. When members of misunderstood communities challenge the stigmas placed upon them, we’re often tokenized and flattened out. Our culture is uncomfortable with people possessing a complex mix of identities, so we try to reduce them to the most digestible version of those identities. This feels especially true online.

This issue is a big part of why I mostly stopped writing about atheism a few years ago. Instead, I traveled the country talking about atheism and interfaith engagement and worked as a full-time nonreligious community organizer. Now, I’m collaborating with humanist organizations and universities to research the religiously unaffiliated and explore the creation of humanist centers to support them.

My experiences helping people better understand atheists have been deeply rewarding, and so has working to support atheists struggling with life’s challenges or with families that don’t accept them. I can say without hesitation that my shift from blogging about atheism to community-building was the right decision.

I enjoyed it in the past, but I don’t expect to write as much online about atheism in the future. I’ve lost a lot of my optimism about the power of online discourse to help religious and nonreligious people understand one another better.

In the age of Trump, building safe communities for the nonreligious and uniting people of all faiths and philosophies to advance the common good feels critical. But I’m finding other ways to advocate for these things — ways that, for the most part, probably won’t involve going on Fox News or regularly blogging about atheism.

I’m still an atheist, but I’m not sure I believe in writing about it online anymore.

Clarification: An earlier version of this piece attributed a debate sponsored and supported by multiple groups to one of them. This reference has been removed to avoid confusion.

Chris Stedman is the author of “Faitheist,” and his writing has appeared in the Guardian, CNN, MSNBC and Salon. After serving as a Humanist chaplain at Harvard University and director of the Yale Humanist Community, he now lives in Minnesota, where he is a writer, speaker and nonreligious community organizer. He is working on his second book and writing a column for INTO called “Exposed.”