Customers riding with Uber and Lyft will spend less than they would on the same ride with a taxi almost all the time, except in the hours that the transportation companies have surge pricing in effect. That’s the result of a new study from What’s the Fare, a site meant to help customers determine once and for all the best way to get around.

The study comes after Uber and Lyft, themselves rivals, have spent years sparring with the taxi industry and local regulators over their right to ferry customers through urban areas. There are a lot of factors at work, the researchers concluded, so a customers’ best bet is to compare their options before ordering a ride.

“While collectively ride-sharing services are almost always cheaper than taxis, individually there’s more variability,” What’s the Fare creators Matthew Liu and Jonathan Goldman wrote in a blog post announcing their results. “In Los Angeles any of the ride-sharing services are cheaper than taxis over 95 percent of the time. But in San Francisco and New York, UberX only winds up cheaper than a taxi three out of four rides, and Lyft is cheaper 72 percent and 64 percent of the time, respectively.”

Liu and Goldman spent weeks comparing Uber and Lyft’s publicly posted rates with taxi fares, applying the fees to the distance of each trip on Google Maps.

Uber in particular has sought to attract customers by intermittently lowering its price beneath a New York City taxi’s fare. Yet customers, and now the Better Business Bureau, cited Uber’s confusing surge-pricing policy as a point of frustration, with the company increasing fares at particularly busy times, or when drivers become scarce. Similar objections have been raised over Lyft’s Prime Time program.

“While dynamic pricing is often portrayed as an infrequent occurrence during busy periods, we see from these charts that it’s actually in effect very often,” the blog post goes on. “Lyft’s Prime Time seems to be in effect more often overall than UberX’s Surge and Prime Time aim to exchange reliable pricing for reliable availability, but it’s worth noting that dynamic pricing is used far more often than most would expect.”