Two window maintenance workers more than 50 floors in the air were suddenly and precariously left hanging Wednesday afternoon as stunned onlookers watched from the ground and surrounding towers.

The men were working on the 6th Street side of the Wells Fargo Center in downtown Minneapolis, between Nicollet Mall and Marquette Avenue, when the basket holding them malfunctioned, according to the Minneapolis Fire Department.

Ryan Trebil, who works for Abbot Downing, a wealth management company in the building, saw the maintenance workers on the scaffolding from the 51st floor of the Wells Fargo Center. Next, Trebil said he saw ropes dangling, and heard the scaffolding slam into the building as the workers yelled.

Nathan Elleson, 23, from Chicago, was watching the accident from the Westin hotel across 6th Street. “I saw one guy swinging from the scaffolding,” Elleson said. “Luckily, he got swung back into it.”

The malfunctioning scaffold made a “big thump” when it gave way, Elleson added, “and that’s when the crowd started gathering.”

The life-or-death drama continued for about 15 minutes until firefighters were able to reach the scene and bring the men into the office tower from the free-swinging scaffolding through a window on the 50th floor.

Fire Battalion Chief Kathleen Mullen said the two men came away uninjured. “The two workers are OK and do not need medical attention,” a follow-up Fire Department tweet read.

About 14 people in all were involved in the rescue.

At 1:53 p.m., someone in the building called about the workers. Fire rescue teams arrived, and building security opened the window on the 50th floor, where the workers were brought into the building, Chérie A. Penn, assistant fire chief, said in an e-mail.

The 57-story building, opened in 1989, is the third tallest in downtown Minneapolis, after the IDS Center and Capella Tower.

Timothy Baynard, battalion fire chief, said he believed that two workers on the scaffolding worked for Restoration Systems Inc. of Chaska.

A call to Steve Dronen, president at Restoration Systems, elicited a different view of the afternoon’s events. The midafternoon emergency call at the tower was “erroneous,” Dronen said in a statement.

“We had no incident requiring emergency assistance today at the Wells Fargo Tower,” Dronen said. “Our workers, who were replacing window gaskets, exited scaffolding unassisted.”