SAN FRANCISCO — Code2040, a San Francisco nonprofit working to increase diversity in the technology industry, has raised $5.6 million to fuel a major expansion as it navigates a tense political climate.

The new funding from the John S. and James L. Knight Foundation and others comes as diversity advocates face a sharp backlash over their efforts to bring groups of people long marginalized by the tech industry into companies that remain largely white and Asian male.

The broadsides against diversity began after last year's election of President Trump that brought attacks on initiatives that prioritized women and people of color and heated up with the firing in August of a Google employee who blasted the company's diversity policies.

James Damore, an engineer, argued in a memo that women were not equally represented in engineering in part because they were biologically less capable. He was embraced in conservative circles that accused Google — and more broadly Silicon Valley — of engaging in political correctness and censoring dissenting opinions.

Heightened tensions hijacked the conversation about diversity and made some people in the tech industry less comfortable publicly supporting the work that Code2040 and others are leading, says Code2040 co-founder and CEO Laura Weidman Powers.

"It was one thing when President Obama was in office and he used to talk about diversity in tech and he paid attention to how tech and Silicon Valley were thinking about these issues. Now that external pressure is lost," says Weidman Powers, who served as a senior policy adviser in the Obama administration, focusing on diversity and inclusion in tech hiring and entrepreneurship.

"For folks who are motivated by their own sense of conviction, that doesn't matter necessarily. But for folks looking at the way the wind is blowing, there is less inclination to prioritize this work," she said.

That's an unwelcome setback for CODE2040, which relies in part on gifts from wealthy individuals and institutions to support its efforts preparing college-age African-American and Latino technical talent for careers in the tech industry through internships that place them in tech companies whose narrow recruiting efforts often overlook them.

Code2040 has redoubled its efforts, broadening its focus to tech roles in other industries and expanding to New York City with partners such as Goldman Sachs, Spotify and the New York Times.

With the new funding, Weidman Powers says Code2040 will press forward on other fronts as well. The John S. and James L. Knight Foundation gave $3 million. The rest came from the foundation of Twitter co-founder Evan Williams and his wife Sara, an anonymous donor and some other individuals and companies, according to Code2040.

— Code2040 says it plans to increase the number of students participating in its programs to 1,000 from fewer than 200 in 2017.

— It's looking to grow its overall community more than sevenfold to 40,000 by 2020. This community will include black and Latino techies and their allies, from colleagues to policymakers to industry leaders, Weidman Powers says.

— And Code2040 is launching a team to coach companies on how to diversify their corporate cultures. That team will create curriculum based on the insights Code2040 has gleaned from working with dozens of tech companies.

With the growing influence of the tech industry in every facet of American life and workplace, it's imperative that more women and minorities gain access to the high-paying, fast-growing jobs it offers, Weidman Powers says. She sees employment in technical roles as a key step in closing the wealth and achievement gap in the U.S. for African Americans and Latinos. Code2040's name refers to the decade in which the United States will reach a non-white majority.

Data show many more black and Hispanic students major in computer science and engineering than work in jobs in the tech industry. Nine percent of graduates from top engineering programs are black and Hispanic, according to a recent report from the Equal Employment Opportunity Commission. Representation for blacks and Hispanics at major technology companies is about 5%. USA TODAY analysis of the employment records of Facebook, Google and Yahoo revealed that African Americans and Hispanics are also sharply underrepresented in non-technical jobs such as sales and administration.

Weidman Powers says she was disappointed to see support for that effort waver with attacks on Silicon Valley diversity initiatives by the so-called alt right.

"I think it has created a sense of fear in folks who see this work as optional. There's a group of us, and it's strong and growing, that recognizes this work is not optional. This is the fundamental economic thread of the civil rights movement of the 21st century," she says.

She's hoping Damore's controversial memo and the aftermath will turn out to be a temporary distraction that briefly waylaid a far more important conversation: "What are the systems, policies and practices that are failing us in recognizing talent from all backgrounds?"

"It was a really disappointing chunk of the year that was engulfed in defending our right to actually participate in the economy as opposed to analyzing what barriers exist to that participation," Weidman Powers says.