The most interesting part of Google’s proposed new headquarters is not the open-air layout, the glass canopies or the wild renderings — it’s how the company had hoped to convince Mountain View to approve the project. Google offered $240 million in community benefits in exchange for the California city granting the company development rights for millions of square footage in the North Bayshore area. It’s an offer that was, at once, generous and highly self-interested, as you might expect from a company that is more powerful — and far richer— than most countries.

But in hour five of a special meeting of the Mountain View city council, it was clear that would not be enough. This tiny city has Google fatigue, and no amount of parks, bike lanes, free buses or other community benefits can make up for the fact that Mountain View is apparently uncomfortable with being a company town.

Ultimately the city council voted four to three to allow less than one-quarter of the construction Google had hoped for, in favor of an expansion proposal by LinkedIn, which came with far fewer community benefits. David Radcliffe, Google’s vice president of real estate, was visibly upset by the vote, characterizing it as a “significant blow” to the company, which has grown to expect getting what it wants from Mountain View.

City bureaucrats often characterize themselves as victims of large tech corporations that threaten to “overrun” their towns. But the reality is far more complex. The relationship between a giant, global corporation and a tiny municipality is a strange one, unbalanced and yet in many ways symbiotic. Tech companies are not colonizing cities against their will. Cities need tech money; and tech needs city support — especially as more companies buy more property all over Silicon Valley, planning for greater growth. The result is a redefining of local public-private partnership. Where cities once ran on tax dollars, selective corporate philanthropy has emerged as a significant driving force of urban policy. Tech companies are reengineering city streets, building city police stations and parks, and even helping cities cover the salaries of the public servants they rely on.

It’s not clear whether these community benefits are an expression of heartfelt corporate responsibility, or an effort to control local planning and policy. Is this much-needed civic philanthropy, or a new spin on the old company town?

The construction of Silicon Valley began unassumingly enough, a few thousand acres here and there around the stone fruit and almond orchards that bloomed here in the 1950s. Over the next 30 years, the sprawling concrete office parts overtook the apricots, the cherries and the plums, and America’s preeminent tech metropolis emerged.

But while tech was booming, California municipalities were beginning to go bust. The passage of Proposition 13 in 1978 prevented the annual reassessment of property value, slashing the main source of local tax revenue. Where property taxes once paid for streets, schools and public safety, California cities increasingly turned to regressive taxes, fees, debt and public-private partnerships to bankroll everyday local needs.

In the ’80s and ’90s, fostering retail business and raising sales tax rates helped to make up some of the difference. But while this helped give birth to American shopping mall culture, it didn’t lift cities out of the red. Desperate to attract business and development and willing to do whatever they could to get it, cities turned to hefty subsidies and tax breaks.

By the late ’90s, communities affected by all that new development began to push back. A movement demanding that developers give back to the neighborhoods hosting them took off in earnest in 2001, with the successful signing of a community benefits agreement tied to the development of a publicly subsidized sports and entertainment district in Los Angeles. Known as the Staples Center CBA, the agreement required the developer to hire local residents at a living wage, build affordable housing, and make a $1 million investment in public parks and recreation facilities. When the developer actually delivered on the agreed-upon benefits, organizers around the country took notice.

Since the Staples Center deal, dozens of formal community benefits agreements have been implemented in the U.S., to varying degrees of success. They have to a great extent become a presumed part of any major California urban development, though they can be just as easily manipulated as any other development deal.

It’s in this political climate that today’s tech giants began to construct their palatial office park campuses across Santa Clara County, offering community kickbacks in the form of CBAs as well as less formal agreements. While companies have always engaged in lightweight local philanthropy — donating to schools, sponsoring Little League teams — these new arrangements operate at a different scale. Not a barbecue for public safety, but a new public safety building; not a computer lab for an elementary school, but a computer for every student in every school in the district. And while corporate giving has always been about burnishing local reputations, in Silicon Valley it’s also about living up to a lofty brand identity that espouses certain social values and cultural mores.

In 2013, Apple broke ground on its new 2.8-million-square-foot headquarters in Cupertino, with a presumed completion date in 2016. The company’s own economic impact report claims the new campus would generate an extra $3.8 million in annual taxes for the city, 9,200 construction jobs and 8,000 more jobs at Apple when the office is complete.

Apple’s community benefits package is directly related to the impact of this new massive office complex and the thousands of new employees who will work there. The company will spend nearly $100 million on renovated public utilities, streets infrastructure and transit programs in the immediate area. The city also received more than $30 million for the sale of the land to Apple, and one-time development fees and taxes. Apple is already Cupertino’s single-largest taxpayer, but the company claims the new campus will offer much more comprehensive benefits to Cupertino in the form of increased patronage of local businesses. Apple, according to Apple, “has an unusually high multiplier effect on the regional economy.”

In nearby Menlo Park, Facebook is expanding quickly. The company’s development contracts with the city provide for the usual construction fees, plus one-time streets improvements, public art installation and a total of $2.6 million in public benefit payments made to the city general fund.

But where Apple has ostensibly aimed to offset the company’s local impact, Facebook’s giving reaches far beyond the social network’s corporate domain and its ever-growing Menlo Park campus. Facebook doles out gifts and grants to dozens of community groups and nonprofits in Menlo Park, and strongly encourages employees to volunteer for local causes, especially relating to local youth STEM education.

The company’s most unexpected donation came in 2014. That year, Menlo Park Mayor Ray Mueller cut the ribbon on a new police substation, built and bankrolled by the social network. Facebook will pay the salary of an additional Menlo Park police officer as well as the rent of operating the substation, located in the low-income Belle Haven neighborhood, for another two years. At the time, Mueller compared the arrangement to a sponsored concert venue or sports stadium. “I think there is precedent for taking money from private companies and putting it to public good,” he told Ars Technica. Facebook’s head of global real estate and security John Tenanes commented that the company is “trying to be good neighbors.” Facebook designed the substation from top to bottom, down to the booking benches for prisoners that it had built from scratch. According to emails obtained from the city, city manager Alex McIntyre refers to it more than once as “the Facebook substation.”

“The city staff works closely with Facebook representatives and has a very good relationship with them,” says McIntyre. The company is “quite involved” in the update to the city’s general plan, and Menlo Park has hired an additional seven city staffers to handle all the increased development activity. In emails, Tenanes complains about delays in development permit approval, and offers Facebook’s “project management expertise” to the city. “Please let us know if we can be of assistance.” The city manager and head of public works agreed that the offer was “interesting.”

Google gives millions more to its hometown of Mountain View than Facebook or Apple give to theirs, but the tech giant’s growth has been an ongoing strain on the city. In community benefits both formal and informal, Google has attempted to use its tremendous wealth to make up for its tremendous footprint. The company has quietly lobbied for an extra carpooling lane on Highway 101 to accommodate its daily stream of employee shuttles, funded the construction of city bike lanes, and bankrolled a free local public bus, with the hope of alleviating some of its impact on the local community, which still complains of heavy traffic.

In 2012, Mountain View and Google entered into a $222,000 annual contract for Google to pay for city planning staff to handle all the reviews needed to get Google’s projects off the drawing board and into construction phases. Today, that contract is valued at $377,838. While the city normally charges companies an hourly rate for municipal services, the vetting of Google projects required more hours than the city had available. Instead of rejecting the company’s plans outright for lack of staff, Mountain View asked Google to fund the hiring of two additional planners. It was an unusual arrangement, the kind usually reserved for corporate polluters that must pay for large-scale government cleanups.

The agreement to have Google subsidize public servants didn’t necessarily raise many local eyebrows. After all, like it had before, Google solved the problem it had created, albeit by playing a major role in government affairs.

But local will for such involvement appears to have waned. In rejecting the vast majority of Google’s campus expansion, the Mountain View city council also rejected most of the company’s $240 million community benefits package, from the bike lanes and affordable housing, to the $15 million public safety center and ecological restoration, all planned at Google’s behest and design.

The vast majority of the North Bayshore area was instead granted to LinkedIn, which offered far fewer community benefits, but had one major factor in its favor: It’s not Google.

The political climate for tech companies in the Bay Area is, to a great extent, confused. The Googles of the world are blamed for a sharp rise in the cost of living and an increased strain on public services and infrastructure, but at the same time, no one can deny the huge boost they’ve given local government coffers.

Still, there is a discrepancy between the billions of dollars these companies make and the checks they write to the local governments that host them.

The sales tax model that served California cities for decades doesn’t work in the knowledge economy. While Apple remits local tax on the products it sells, Google and Facebook don’t collect sales tax on the digital ads we click away and the data we unwittingly share. Community benefit deals can potentially bridge the gap between those taxes and impacts, but they allow companies to determine which civic projects should be priorities. Facebook might want more police and Google might want more local ecology — but what do residents want?

If cities want to take greater control of their future, they’ll have to create and enforce new tax revenue streams — something Mountain View council member Lenny Siegel says he is working toward.

Without a significant local tax burden, companies can afford to drive policies and services, superseding the role of local government and advancing their own ideology. When that ideology includes bike lanes and public school support, this arrangement might work well.

But in a region in the grips of a controversial housing crisis spurred in no small part by an influx of high-paid tech talent, Silicon Valley companies on the whole appear comparatively disinterested in funding the affordable homes these cities so desperately need.

Of more than $100 million in community benefits for its new campus, Apple is paying only $2.5 million to Cupertino for the construction of affordable housing. Facebook subsidized 15 affordable units in an apartment complex now under construction, but a source at the company was dismissive of the idea that the social network would become a major player in local home building. The company’s proposed housing projects, largely if not solely restricted to Facebook employees, recall a robber baron era of worker welfare.

In contrast, Google has been a vocal supporter of affordable housing. “As a region we are not where we want to be in terms of housing,” the company noted in a proposed community benefits agreement, in a section detailing proposed sites for new home construction. The tone is even a bit passive-aggressive: “It is hard to address a challenge like this if you’re not prepared to discuss it openly, and with facts.” Google’s failed CBA included a plan for affordable units and a $900,000 commitment for the formation of an affordable housing advocacy group.

But Silicon Valley might be even less interested in building those homes. For the thousands of new jobs expected to come to North Bayshore in Mountain View, the city council has approved only up to 1,100 new units of housing — and even that was considered a victory.

As San Francisco has emerged as the preferred bedroom community for many young techies who travel south on company shuttle buses to work, many in that city blame their own housing crisis on a culture of NIMBYism that still longs for the lost Valley of Heart’s Delight, the orchards of stone fruit and almonds razed decades ago, and the quiet life of the communities tucked around them.

In fact, none of the cities in the region planned for Apple or Google or Facebook, or their attendant demands. Some fear that company housing projects would create a strong local tech voting bloc — a mark of a true company town.

Even when they do get the benefits they want, a small municipality has reason to fear becoming heavily reliant on one big player. After all, Mountain View once had Intel and Sun Microsystems; Hewlett-Packard packed up its Cupertino office in 2012. That’s a big loss to a tiny city, but the region remains largely unchanged. Mountain View may not want millions more square feet of Google office space and the community benefits that come with it, but another town just down the road likely will.

A strong “gospel of wealth” ethos runs through Silicon Valley, a pervasive sense that these companies, in their quest to change the world for the better, must also be socially responsible with their profits. Dozens of Silicon Valley founders and executives have signed Bill Gates and Warren Buffett’s Giving Pledge to donate half or more of their personal fortunes. But the question of why their companies would also engage in this form of philanthropy remains open. Do they just want to be nice — or at least not evil, as the Google motto intones? Or do these projects have more ambitious and experimental ends?

Big companies in small cities are bound to exert some of their own power, either purposefully or passively. Much of this seems inevitable — it’s how this valley was named “Silicon” decades ago. But these companies are no longer dealing just in silicon. Regardless of Google’s loss in North Bayshore, soon Mountain View will feature Google-designed cars running on Google-funded roads planned by Google-paid city engineers. Where they once built semiconductors and software, tech is shaping the future of human communication, infrastructure, transit, law and collective lived experience — all the things that make up a city.