TORONTO — As the streetcar crept along Queen Street West in clogged traffic through the heart of downtown, anxiety started to rise among those inside. Commuters checked the time, calculating how late they would be for work.

The red-and-white trolley did not feel like rapid transit.

“It’s not very efficient,” said Shande McPhee, who was a half-hour late for her financial-industry job on a recent morning because of worse-than-usual congestion. If only the streetcar had a dedicated lane to bypass cars, she said.

Despite flare-ups of grumpiness, tens of thousands of people in Canada’s largest city rely on the vehicles to get around on North America’s largest streetcar system.

Now that New York City is bringing back the streetcar, with Mayor Bill de Blasio planning a $2.5 billion waterfront route linking Brooklyn and Queens by 2024, officials are looking to Toronto for lessons on how to make the new line a success. Even in Toronto, where trolleys have rattled down streets for nearly a century, the streetcars have often prompted rancorous debates — which will undoubtedly soon be coming to New York.