The duo say they want to represent all staff discriminated against due to their "perceived conservative political views, male gender and Caucasian race".
James Damore, fired last year over a controversial memo, is behind the suit.
His memo argued there were few women in top jobs at the firm due to biological differences between men and women.
Mr Damore and David Gudeman, another former engineer at the firm, filed the suit at Santa Clara Superior Court in California.
A spokesperson for Google said they "look forward to defending against Mr Damore's lawsuit in court."
A separate case filed by three women who used to work at Google, alleging it pays women less than men for comparable work, was dismissed last month, but has been refiled in an amended form.
Mr Damore and Mr Gudeman claim in their lawsuit that Google employs illegal hiring quotas to fill posts with women and minorities.
They accuse the company of failing to protect employees with conservative views, including supporting US President Donald Trump.
Their lawsuit says the men were "openly threatened and subjected to harassment and retaliation" at the company, which they describe as an "ideological echo chamber".
It says Google "openly shames" managers who fail to meet goals, even booing them at meetings.
Mr Damore's memo caused fierce debate about free speech in the workplace and diversity in Silicon Valley.
The memo's focus on perceived biological differences between men and women proved highly controversial.