We’re driving north along the San Francisco waterfront in Toyota’s new fuel-cell sedan when the smooth, rounded rear of a Tesla Motors Model S pulls into the lane in front of us.

Like the Model S, Toyota’s latest clean car runs on an electric motor — no gasoline required. Unlike the Model S, the sedan doesn’t get its energy from a big battery pack. Instead, a hydrogen fuel cell beneath the front seats feeds a steady stream of electricity to the motor.

The cars represent two different visions of gas-free driving. And starting next year, they will go head-to-head in California, in what some alt-car aficionados consider the VHS vs. Betamax battle of our day.

MBA BY THE BAY: See how an MBA could change your life with SFGATE's interactive directory of Bay Area programs.

“The Tesla’s great technology, but it’s still a niche product,” said Jana Hartline, environmental communications manager for Toyota, who’s riding with me as I head north on the Embarcadero. “It’s one thing to bring a new technology to market. It’s another to bring it to the mass market.”

And Toyota, the world’s largest automaker, is convinced that fuel-cell cars better suit the mass market than pure electrics such as Tesla ever will.

The Toyota sedan, due to go on sale in California sometime next year, can travel more than 300 miles before needing to refuel with hydrogen. And assuming that the driver has easy access to a refueling station — still very, very rare — filling up takes just a few minutes. Most electrics go 100 miles or fewer on a charge and need at least an hour to fully juice up their batteries.

Tesla’s Model S is the exception, with a range exceeding 265 miles. But its price starts at $71,070 and runs north of $100,000, depending on options. Toyota insists that fuel-cell vehicles can offer better range at lower prices than battery-powered electrics, although the automaker has yet to reveal the price of its fuel-cell sedan.

“One thing you’ll probably never see is a pure electric replacing the internal combustion engine, at least for range,” Hartline said.

Toyota also hasn’t revealed the sedan’s proper name, or the design of its interior cabin. But the Japanese automaker did let me test drive one of the prototypes, or “mules,” around San Francisco.

It feels much like the current crop of pure electrics — quiet and fast. It doesn’t have the lightning acceleration of the Model S, or of the electric Rav4 that Tesla and Toyota designed together. But it jumps out of a stoplight quicker than most gasoline cars, with almost no noise.

When at rest, it can be hard to tell that the car is on. Turn it off, and there’s a soft hiss as the fuel cell shuts down. Unlike pure electrics, the sedan has a tail pipe. But the pipe’s mouth is flush with the underside of the car, so you can’t see it. All that comes out is a dribble of water, the by-product of the fuel cell’s electrochemical reaction between hydrogen stored in two tanks and oxygen sucked in through a slit-like vent beneath the hood.

Handling is smooth, although indistinguishable from an ordinary sedan. That may be part of the point. Although Toyota has spent more than a decade developing fuel cells, they’re a novel technology to drivers. The company wants the car to feel first and foremost like a car.

The production model sports a sleek body and broad, bold front highlighted by two big air scoops that feed the cooling system. The shape has hints of other Toyota models, but it isn’t based on any of them, with designers styling a new body from the ground up.

Toyota has already tested its fuel-cell technology in other cars not offered to the American public, including an SUV that has logged more than 1 million miles of travel since 2007. Jared Farnsworth, senior engineer with Toyota’s fuel-cell program, says he’s tested the cars in weather extremes that include air temperatures down to minus 41 degrees. They worked.

“You see all these high daunting hurdles, and it’s cool to see we can overcome them,” Farnsworth said.

Whether people are willing to buy fuel-cell vehicles remains an open question.

In June, Hyundai started offering a fuel-cell version of its Tucson crossover vehicle to drivers in Southern California, but only with a $499-per-month lease. And Hyundai will cover all refueling costs at the region’s handful of hydrogen fueling stations. California has just nine stations now (the Bay Area has one, in Emeryville) although 49 more are under development. And the most common way of producing hydrogen involves stripping it from natural gas, a process that releases the greenhouse gas carbon dioxide. To many eco-conscious drivers worried about global warming, that limits the fuel cell’s appeal.

Farnsworth views pure electric vehicles and fuel cells as complementary — not competing — technologies. Pure electrics charge up at home and work great for urban driving. Fuel cells can be fueled quickly in much the same way as gasoline-powered cars, and they can easily scale up in size.

“It’s not an 'or’ question — it’s an 'and’ question,” Farnsworth said.