Silicon Valley firms have long been known for offering a litany of employee perks: Home-cooked lunches, free massages, climbing walls and dog-friendly offices.

Now some are adding yet another incentive to attract — and retain — workers: Paid time off to protest.

Fauna, a San Francisco-based database start-up, recently began allowing its 13 employees to take unlimited paid leave to participate in rallies, vote, write letters to elected officials and take part in other civic activities. Before February, employees could take time off on an as-needed basis. But the political climate — and polarization — following President Donald Trump’s inauguration called for more defined measures, said Amna Pervez, director of recruiting and retention.

“Since there’s been such a divide in our country, we felt we should be very explicit about our policy,” Pervez said, adding that the company also provides unlimited vacation time. “We want our employees to know that we absolutely support the betterment of our country. People can take whatever they feel like they need to make a meaningful difference.”

A number of other start-ups, including Turbine Labs, Buoyant and Jelly Industries, have signed on to do the same. The new policies come as technology firms and other companies take a stand against the Trump administration’s plan to tighten restrictions for foreign workers. On Tuesday, Trump was expected to sign an executive order that would impose new restrictions on H1-B visas, a type of temporary work visa often used by firms to recruit and employ highly-skilled workers.

“If you’re a tech company, taking a pro-immigration stand is not exactly a bold move,” said Peter Cappelli, a management professor at the Wharton School. “When there’s a tight labor market and companies are fighting for programmers, this is a way to say, ‘See? We’re here to support you.’ ”

Facebook, for example, is allowing its employees to take time off to participate in pro-immigration rallies on May 1. The company, which relies heavily on foreign workers, informed employees and contractors last week that they would not be penalized for missing work to protest, Bloomberg reported Tuesday.

“At Facebook, we’re committed to fostering an inclusive workplace where employees feel comfortable expressing their opinions and speaking up about issues that are important to them,” a company spokesman said in an email. “We support our people in recognizing International Workers’ Day and other efforts to raise awareness for safe and equitable employment conditions.”

Facebook could be particularly hard-hit by any changes the Trump administration makes to H-1B visa policies. More than 15 percent of its employees used temporary work visas last year — a higher percentage than at Google, Apple, Amazon or Microsoft, according to a Reuters analysis of U.S. Labor Department filings.

At Atipica, a software start-up in San Francisco, four of the company’s five U.S.-based workers are immigrants. Founder Laura Gómez, who is from Mexico, said it was a “no-brainer” to give workers paid leave to make their voices heard.

“At this point in our political reality, it’s really, really important to allow my employees to do something that not only affects them, but also the direction of our country,” she said. “This is what democracy looks like: People having the freedom to stand up for what they believe in.”

There are some ground rules, though: No violence, or activities that make others feel threatened.

“We will define this as we grow,” Gómez said. “But my hope is that policies like this become the norm. When Google began giving out free lunches, everyone else followed. Why should this be any different?”

For her part, Gómez said, she plans to participate in a pro-immigration march on May 1.

“I’ll be out there,” she said. “And hopefully the rest of the company will, too.”