Will Amazon's HQ2 be a good neighbor or a nightmare? Editor's note: An earlier version of this video contained outdated population and incentive figures. (Video: Daron Taylor/The Washington Post, Photo: Daron Taylor/The Washington Post)

(Update: The Amazon HQ2 locations are revealed — and so is the price tag)

Amazon will open major new outposts in Northern Virginia’s Crystal City and in New York City, splitting its much-sought investment of up to 50,000 jobs between the two East Coast sites, the company announced Tuesday.

“We are excited to build new headquarters in New York City and Northern Virginia,” Amazon founder and CEO Jeffrey P. Bezos said in a statement. “These two locations will allow us to attract world-class talent that will help us to continue inventing for customers for years to come. The team did a great job selecting these sites, and we look forward to becoming an even bigger part of these communities.”

The company also announced that it has selected Nashville for 5,000 jobs as part of a new Center of Excellence for its Operations business, which is responsible for the company’s customer fulfillment, transportation, supply chain and similar activities.

Amazon HQ2 to receive more than $2.8 billion in incentives from Virginia, New York and Tennessee

The choice of Crystal City in Arlington County as one of the winners cements Northern Virginia’s reputation as a magnet for business and will potentially reshape the Washington region into an eastern outpost of Silicon Valley over the next decade.

The selections came with a price tag, details of which are just becoming public. Virginia Gov. Ralph Northam (D) and Arlington County leaders agreed to give Amazon $819 million based on the company creating 25,000 jobs with an average wage of $150,000.

The money, which is subject to approval by the Virginia General Assembly, also includes $195 million in transportation improvements to nearby Metro stations, Reagan National Airport and to construct pedestrian bridge connecting to company’s new hub, which will be in a newly-branded neighborhood called “National Landing, encompassing parts of Pentagon City and Crystal City in Arlington and Potomac Yard in Alexandria.

Virginia Tech plans to build a $1 billion graduate campus in Alexandria focused on innovation, part of the higher education offerings the state offered the company.

Read Virginia’s agreement with Amazon

New York leaders offered more — $1.85 billion, much of it also tied to the company’s job growth and salaries.

The decision hands Northam and local leaders the largest economic-development prize in a generation — one promising billions of dollars in capital investments alone — but could also put pressure on the region’s already steep housing prices, congested roads, and yawning divide between wealthy and low-income residents.

Northam, in a statement, said he expected Amazon to invest $2.5 billion in the commonwealth and create $3.2 billion in tax revenue. He is expected to make the announcement at a Tuesday afternoon event.

According to a 25-page agreement between the company and the state, Amazon expects to hire 400 people in 2019 and 1,180 the next year. It expects to create a minimum of 25,000 jobs by 2030 and potentially a total of 37,850 by 2034.

“This is a big win for Virginia — I’m proud Amazon recognizes the tremendous assets the Commonwealth has to offer and plans to deepen its roots here,” he said.

It also represents a victory for New York Mayor Bill de Blasio (D) and Gov. Andrew M. Cuomo (D), who had joked that he would change his name to “Amazon Cuomo” if necessary to land the project.

How can the D.C. region absorb an Amazon headquarters if it can’t cope now with gridlock and housing costs?

Other final suitors included the District, Montgomery County and 16 other jurisdictions Amazon considered since narrowing its list in January. D.C. Mayor Muriel E. Bowser (D) and Maryland Gov. Larry Hogan (R) both applauded the announcement.

Neither will have to pony up incentives to the company, but experts say both should see economic gains as a result. Bowser called on regional leaders to create concrete affordable housing goals — an acute problem that economists say is likely to worsen as Amazon grows.

“Amazon in Arlington is a win for D.C.,” Bowser said in a statement. “We will continue preparing residents with the skills and knowledge they need for the jobs of the future, including at Amazon.”

Northern Virginia property owners are delighted Amazon HQ2 is moving in. Renters, first-time buyers, and low-income residents aren’t.

Hogan said he expects to see other companies relocate to the region to be near Amazon. “Collectively, we will not only gain 25,000 corporate-level jobs, but also many businesses that are part of Amazon’s supply chain,” Hogan said.

AOL co-founder Steve Case, who now works with tech entrepreneurs in smaller cities, issued a statement encouraging them not to lose faith despite the selection of two East Coast stalwarts.

“The best economic strategy is not to lure existing companies to open offices or factories, but instead to birth the new companies that could be the Amazons of tomorrow,” he said. But in the same breath, the longtime Northern Virginia resident took a victory lap: “Amazon’s announcement is a win not just for VA, but also for the entire greater D.C. region.”

Opposition to the move started shortly after the announcement, as groups dedicated to fighting inequality and opposed to corporate subsidies began rallying their supporters in both New York and Virginia as details of the deal began to emerge.

“We’ve been getting calls and outreach from Queens residents all day about this. The community’s response? Outrage,” said Rep.-elect Alexandria Ocasio-Cortez (D-N.Y.), who will take office in January.

Many were concerned about the cost of living and questioned why a company run by Bezos — the world’s wealthiest person — needed any public funds.

“Thousands of new high-paying jobs could be a boon to our community, but we deserve to know the cost,” said Anna Scholl, executive director of the advocacy group Progress Virginia. “Tens of thousands of new workers and their families are sure to strain community resources when it comes to affordable housing, mass transit and traffic, and quality local schools. It’s only right that Amazon pay their fair share.”

Jay Carney, Amazon senior vice president of worldwide corporate affairs, said that the company considered all the locations carefully and reviewed 100 different metrics, but ultimately made its decision — including the choice to split the project — based on how best the company could recruit the talent it needs.

“We came to realize that of course these are two fantastic metropolitan areas, and each of the areas has an existing pool of talent and are fantastic places to live,” he said in a phone interview.

How Crystal City, the future home of Amazon’s new headquarters, got its name

Carney said that Amazon would apply some of the lessons it had learned from its growth in Seattle to its new locations. He said Bezos was “involved very deeply” in the process and was in every leadership meeting where it was discussed.

Amazon’s decision to split the project rather than open a second headquarters on par with its Seattle campus has angered some who said the company had ginned up competition among cities only to change the rules midstream. Some said it was unfair that the company seemed to be considering only sites in more affluent communities.

“One thing that’s different here is we are planning in advance with these cities. Amazon started in a garage. Nobody foresaw, not even Jeff, when they got launched that Amazon would become what it became or that we would have tens of thousands of employees in Seattle alone,” Carney said.

Amazon launched the project in the fall of 2017, dubbing it HQ2 and issuing search criteria for “a second corporate headquarters” with as many as 50,000 jobs and an investment of $5 billion.

Washington won its piece of Amazon’s HQ2. Now comes the hard part.

In picking Crystal City, Amazon opted for a close-in suburban site, just across the Potomac River from Washington and a half-mile from National Airport. Outdated buildings and underused properties now fill the site, where some office buildings have yawning vacancies.

The selection represents a triumph for the growth strategy of Arlington and Alexandria to promote development along mass-transit routes. The site is close to the Crystal City Metro station on the Blue and Yellow lines, and the planned Potomac Yard station scheduled to open in 2021.

But residents in the nearby Del Ray neighborhood in Alexandria expressed worry earlier this year that Amazon’s arrival would worsen daily rush-hour backups that already slow traffic to a crawl, and would erode the quality of life in their neighborhood of mostly single-family homes.

The decision marks a dramatic upturn in fortune for Crystal City, which lost thousands of jobs when military agencies and defense contractors departed in the Pentagon’s Defense Base Closure and Realignment Commission (BRAC) process, beginning in 2005.

The initial building that Amazon will occupy is at 1851 South Bell St. or 1770 Crystal Dr. in Arlington, according to individuals familiar with the decision.

One advantage is that the properties are all overseen by a single, well-capitalized company, JBG Smith. The $4.4 billion firm is the region’s biggest real estate owner and most active developer, and it owns a majority of the property in the bid — enough to accommodate the entire project on its own in Crystal City and Potomac Yard.

Amazon’s choice also burnishes Northern Virginia’s standing as an attractive site for corporate headquarters. In the past 15 years, it has lured Volkswagen Group of America to Herndon, Northrop Grumman to Falls Church, Hilton Worldwide to Tysons and Nestle’s U.S. headquarters to Arlington.

Amazon’s HQ2 split sparks backlash from locals, politicians

Northam said in March that the state’s pitch centered on workforce development, inclusivity and transportation, along with quality of life.

Although 238 locations initially submitted proposals to Amazon, many experts considered the Washington region a favorite from the outset because of Bezos’s personal connections in the region, particularly the $23 million mansion he purchased in the city’s Kalorama neighborhood last year and his ownership of The Post.

Others suggested that Amazon executives wanted to be near Washington to cozy up to the federal government, either because of increased concerns that regulators may pursue antitrust actions against the company or because the government has become a critical Amazon customer.

Virginia also offers the political advantage of being a purple state, making it easier for the company to seek support from both parties.

Amazon previously announced that it would headquarter its cloud computing unit, Amazon Web Services, in Herndon, near some of its data centers.

The Washington area also naturally fit many of the criteria Amazon called for in its search, among them a deep pool of talented workers, a robust public-transit system and easy airport access.

Amazon launched its search in September 2017, vowing to make a decision by the end of 2018 and occupy an initial building of 500,000 square feet in 2019.

The company says its Seattle headquarters has injected $38 billion beyond what the company spent on its buildings into the area economy, generating an additional $1.40 for every dollar the company spent.

Seattle officials have not disputed the figures, but they have also been racing to keep up with the company’s staggering growth and the requirements it places on public transit, schools, road networks, parks and utilities. The company now has more than 45,000 employees, occupying more than 40 buildings and 10 million square feet of office space.

Compared with other large corporations, Amazon employees are less likely to commute by car, as about 55 percent either walk, bike or take public transit, according to a survey the company did of its Seattle workforce. The company purchases transit cards for employees and is building a dedicated cycle track to separate bikes from cars near its Seattle buildings.

Amazon’s growth is also likely to put new strains on housing. Since Amazon’s arrival, Seattle has become one of the most expensive places in the United States to live, forcing lower-income residents to move to far-off suburbs. The city and surrounding King County declared a state of emergency in 2015 over homelessness.

Even without Amazon, the Metropolitan Washington Council of Governments estimated that the region needs to add 235,000 housing units by 2025 to keep pace with expected job growth. Amazon’s arrival could push the goal above 267,000, according to a recent analysis by the Urban Institute. Right now it is on pace to add about 170,000 new units by 2026.

Since beginning the headquarters search, Bezos and the company have made several announcements that could soften Amazon’s image as it moves to open its second hub.

Bezos announced in September that he would donate $2 billion of his own money to support groups battling homelessness in America and to create a network of preschools in underserved communities. In October — after bearing months of criticism from Sen. Bernie Sanders (I-Vt.) over its treatment of workers — Amazon announced that it would raise its minimum wage for all employees to $15 per hour.

The minimum-wage decision isn’t likely to have much effect on the company’s hiring in Northern Virginia, where Amazon says its facility will employ mainly white-collar workers with an average salary of more than $100,000 a year.

Before Amazon announced its search, Washington-area jurisdictions — forced in part by federal budget cuts — had already been diversifying their workforces away from a reliance on federal spending. The region gained more than 55,000 jobs annually from 2015 to 2017 despite budget cuts and stagnation in Congress. But its job growth has been slower than average among major metropolitan areas.

Patricia Sullivan, Gregory S. Schneider, Michael Laris and Fenit Nirappil contributed to this report.