James Damore, an ex-Google employee who wrote a controversial memo arguing the merits of gender and diversity programs, was interviewed by two YouTubers. (Jhaan Elker/The Washington Post)

James Damore, the former Google engineer who was fired after distributing a memo questioning the company’s diversity policies, filed a class-action lawsuit Monday claiming that the technology giant discriminates against white men and conservatives.

Damore’s suit came on the same day that conservative publisher Charles C. Johnson sued Twitter for banning him from the platform in 2015. The cases are the latest signs of a broad effort by some conservatives to challenge technology companies on the grounds that they favor liberal or moderate voices, reflecting the prevailing political sensibilities in Silicon Valley. The technology industry’s crackdown against users accused of “hate speech” after August’s “Unite the Right” rally in Charlottesville has fueled allegations of political bias against companies that are playing a crucial role is disseminating speech worldwide.

The suit by Damore, filed in Santa Clara, Calif., alleges discrimination by Google against men, people of the “Caucasian race,” and people with perceived conservative political views.  The suit says that Google employees who expressed views deviating from the majority at Google on politics or on employment practices, including “diversity hiring policies, bias sensitivity, and social justice,” were “singled out, mistreated, and systematically punished and terminated from Google,” in violation of their legal rights.

Damore’s fellow plaintiff in the class action is another Google employee, a former software engineer named David Gudeman.

Google fired Damore after he wrote a 10-page memo  titled “Google’s Ideological Echo Chamber: How bias clouds our thinking about diversity and inclusion.” Though initially circulated internally in July, it reached a wide audience in August when Motherboard published the memo, saying the “anti-diversity memo” had gone “internally viral” at the Mountain View, Calif.-based technology company. The memo said that “genetic differences” may explain “why we don’t see equal representation of women in tech and leadership.”

The company, which called the memo “offensive” and “harmful,” soon fired Damore, further elevating him in the eyes of his supporters as a victim of what they called an overreaching “political correctness” and ideology rigidity within the tech industry. Damore, who also filed a complaint with the National Labor Relations Board, appeared to embrace his rising political visibility, posing in a T-shirt with the word “Goolag” written in a multicolored style that mimicked Google’s familiar logo.

Google spokesman, Ty Sheppard, said in response to the lawsuit: “We look forward to defending against Mr. Damore’s lawsuit in court.”

At a news conference, Damore’s lawyer, Harmeet Dhillon, said her client had attended various company meetings and discussions dedicated to diversity. At one such event on campus, Damore had questioned human resources staff about whether political bias was included in the company’s diversity hiring goals, and was told it wasn’t. He was asked to contribute feedback after the event, which led him to write his memo. Before the memo went public, he said he had received feedback from nearly 200 different Google employees, including human resources staff, over the course of several weeks. That gave Damore the impression that he was having an open discussion with colleagues, and he did not realize he was in trouble until 48 hours before he was let go.

Damore’s legal complaint filled over 200 pages and included screenshots of emails and other correspondence between Damore and Google employees, and anonymous complaints from current Google employees who hold conservative viewpoints. One screenshot showed an email from a Google engineer who wrote Damore, “You’re a misogynist and a terrible human. I will keep hounding you until one of us is fired.”

Another screenshot shows how a Google employee received a so-called peer bonus — in which a colleague can recommend another colleague for a bonus — for speaking out against the values in Damore’s memo.

The complaint described another Google event, the company’s weekly “all-hands,” in which Google executives “shamed” teams that did not have 50 percent women on staff.

“There’s a Lord of the Flies mentality there,” said Dhillon. “Where a person can be singled out, shamed, and fired.”

Dhillon is a prominent Republican in California who was reportedly considered for a Justice Department position in the Trump administration. She recently represented Republican students at the University of California at Berkeley who sued their school to allow conservative media personality Ann Coulter to speak there on a specific day. (The school had rescheduled Coulter’s event because of security concerns).

At the news conference, held in Dhillon’s office in San Francisco office, Damore was asked whether he was a Trump supporter. He declined to answer.

Later on Monday, Johnson sued Twitter for allegedly violating his right to free speech by permanently suspending his account after a tweet in which he sought to raise money for “taking out” a Black Lives Matter activist.

Johnson filed the suit in state superior court in San Francisco, where Twitter is headquartered. He has long maintained that he was seeking not violence but an investigation that might damage the public standing of the activist, DeRay McKesson. Johnson asserted in the suit that Twitter’s real motivation in banning him was to quash conservative voices online and that the company failed to follow its own “vague and subjective rules” for suspending user accounts.

The suit calls Twitter “the modern public square,” and says, “Like the company towns of old, it is a privately-owned public square. And therein lies the danger.”

Twitter declined to comment on the suit Monday. Like many other technology companies, it has long portrayed itself as a bastion of free speech and said it has acted to block users only after they violate the company’s terms of service, including bans on hateful speech or speech intended to incite violence against people or groups.

Johnson, often described as “right-wing troll” for his aggressive investigations and online tactics, cites in his suit internal Twitter emails published in December by BuzzFeed that appear to demonstrate uncertainty over how to handle Johnson. An email cited by the article says that Johnson was personally banned by Richard Costolo, Twitter’s chief executive at the time. An email that BuzzFeed said came from Costolo said, “To be very clear, I don’t want to find out we unsuspended this Chuck Johnson troll later on. . . . That account is permanently suspended and nobody for no reason may reactivate it.”

Johnson operates two sites, GotNews and WeSearchr, that often have sparked controversy. WeSearchr raises money, called “bounties,” for information and causes that often have a sharply political cast, including money to help defend a neo-Nazi website called the Daily Stormer against a lawsuit by the Southern Poverty Law Center. Twitter has banned Johnson personally and the accounts for GotNews and WeSearchr. GotNews is a co-plaintiff in the suit, along with Johnson.

“Twitter is silencing conversation on the right-of-center perspectives,” Johnson said in an interview. “This has been the standing playbook of how tech companies deal with voices that come from groups they don’t like.”

The American legal system has long given wide latitude to technology companies and the manner in which they choose to enforce their terms of service. But the suit makes particular reference to the California state constitution’s guarantee of free speech. Courts in that state have in the past highlighted the importance of free speech rights even when exercised on private property, making the state potentially more amenable to Johnson’s claims about censorship on a private online platform such as Twitter, said Jonathan Zittrain, faculty director of Harvard’s Berkman Klein Center for Internet and Society.

“Of all the places to bring a long-shot case like this, California would be the place,” Zittrain said.

He added that technology companies, because of their crucial role in airing constitutionally protected speech, need to have rigorous and transparent procedures for deciding when to suspend users.