Dozens of people in two cable cars were left hanging hundreds of feet above the East River for hours on Tuesday when the system lost power because of a mechanical problem.

Both cars of the Roosevelt Island Tramway, which shuttles commuters and tourists between Manhattan and nearby Roosevelt Island, stalled at about 5:15 p.m., stranding about 70 people, said Herb Berman, president of the agency that operates the system. No injuries were reported.

A slow-moving, diesel-powered rescue basket that holds about 10 people shuttled up to the cars, and two police officers began plucking passengers from the cars to take them back to the island.

Police, who delivered food, water and diapers to the passengers, said the effort would take several hours.

Mayor Michael Bloomberg said the rescue effort was going smoothly. At least two groups of passengers had been brought down.

"It does seem to be working exactly the way it was designed," he said.

About a dozen of those stranded were children or babies, Berman said. He did not know what caused the mechanical failure.

The tramcars — which offer breathtaking views of the city from up to 250 feet — were still stalled after midnight while engineers worked to restore power.

One of the tramcars had 46 passengers plus an operator. The other had about 20 passengers and an operator, police said.

On the ground, crowds gathered to watch the rescue. George Teodorescu said he spoke to his father, one of the stranded operators, by cell phone.

"It didn't sound like anyone's being uncivil or anything," he said.

Robbyn Maier said her 12-year-old son, Dax, was going to Roosevelt Island to play tennis when he got stuck. She talked to him by cell phone.

"He's like a trooper through it all," she said.

The tram system, which opened in 1976, is the only commuter cable car system in North America, according to the Roosevelt Island Operating Corp. Web site.

The system has been featured in such movies as "Spider-Man" and "City Slickers." It travels 3,100 feet in about 5 minutes at an average speed of 16 mph, the Web site says. Each car can hold about 125 people.

The cable cars stall occasionally, the last time was around Labor Day, Berman said.

Roosevelt Island, which lies in the East River between Manhattan and Queens, is about 2 miles long and 800 feet wide. About 10,000 people live on the island, which also is accessible by bridge and subway.