Uber’s chief executive has repeatedly defended the company’s controversial, algorithm-driven price spikes, claiming it puts more drivers on the road during periods of heavy demand. But faced with governmental pressure, Uber today announced its intention to cap surge prices in U.S. cities during natural disasters and other emergencies.

The New York Attorney General’s office played a major role in pushing Uber to adopt its new policy, which is finally consistent with New York’s price gouging law. The 35-year-old law bans companies that provide consumers with goods and services from charging “unconscionably excessive prices” during “abnormal disruptions of the market.”

During states of emergency, Uber has promised to keep its prices below that of the three highest-priced days without emergencies of the prior two months. The policy applies to all Uber services that use dynamic pricing, including UberX and Uber Black.

“This policy intends to strike the careful balance between the goal of transportation availability with community expectations of affordability during disasters,” said Uber CEO Travis Kalanick in a statement. “Our collaborative solution with [New York] Attorney General [Eric T.] Schneiderman is a model for technology companies and regulators in local, state, and federal government.”

Uber faced widespread criticism after hiking prices during natural disasters like Superstorm Sandy. But with the new agreement in place, Schneiderman publicly praised the company for cooperating.

“This agreement represents the thoughtful application of long-established law to new technology,” said Schneiderman in a statement. “It provides consumers with critical protections to which they are entitled under the law — and it provides Uber with clarity from government about how the law will be applied to its innovative pricing model.”

The agreement comes just hours after transportation competitor Lyft announced plans to launch in New York, Uber’s biggest market.

VentureBeat's mission is to be a digital town square for technical decision-makers to gain knowledge about transformative enterprise technology and transact. Discover our Briefings.