Accompanied by tug boats, the Viking Sky cruise ship has limped into the Norwegian port of Molde more than a day after issuing a mayday call in a storm that led to harrowing helicopter rescues of half of its passengers.

The Viking Sky carried 1,373 passengers and crew when it had engine trouble Saturday afternoon off the western coast of Norway. Afraid of dashing up on the rocks, it anchored amid heavy seas and high winds and began to evacuate everyone on board.

Amid wind gusts up to 38 knots (43 mph) and waves over 8 meters (26 feet), five helicopters flying in the pitch dark evacuated passengers from the heaving ship throughout the night into Sunday morning. Over 475 passengers were airlifted one-by-one off the ship.

As weather eased, a decision was made to halt the rescues and head to Molde, which it reached about 1530 GMT (11:30 a.m. EST) Sunday.

Five helicopters flying in the pitch dark took the evacuated passengers from the tossing ship in a painstaking process that continued throughout the night. The rescues took place under difficult conditions that included wind gusts up to 38 knots (43 mph) and waves over 8 meters (26 feet).

Some 17 people were hospitalized with injuries, police said.

Passenger Alexus Sheppard told The Associated Press in a message sent from the Viking Sky that people with injuries or disabilities were winched off the cruise ship first. The atmosphere onboard grew calmer after the rescue operation's first dramatic hours, Sheppard said.

"It was frightening at first. And when the general alarm sounded it became VERY real," she wrote.

Photos posted on social media showed the ship listing from side to side, and furniture smashing violently into walls.

"We saw two people taken off by stretcher," another passenger, Dereck Brown, told Norwegian newspaper Romsdal Budstikke. "People were alarmed. Many were frightened but they were calm."

The Viking Sky carried 1,373 passengers and crew members when it had engine trouble in an unpredictable area of the Norwegian coast known for rough, frigid waters. The crew issued a mayday call Saturday afternoon.

Police said the crew, fearing the ship would run aground, managed to anchor in Hustadvika Bay so the evacuations could take place.

Coast guard official Emil Heggelund estimated to newspaper VG that the ship was 100 meters (328 feet) from striking rocks under the water and 900 meters (2,953 feet) from shore when it stopped.

The ship was visiting the Norwegian towns and cities of Narvik, Alta, Tromso, Bodo and Stavanger before its scheduled arrival Tuesday in the British port of Tilbury on the River Thames. The passengers mostly were a mix of American, British, Canadian, New Zealand and Australian citizens.

The airlifts continued at a steady pace Sunday morning, as the vessel was being prepared for towing by two tugboats to the nearby town of Molde, according to Per Fjerd at the Joint Rescue Coordination Center.

The helicopters stopped taking people off the ship when the ship was ready for the trip to shore, and 463 passengers had been evacuated by that time, the Joint Rescue center said. Three of the ship's four engines were working as of Sunday morning, the center said.

The Viking Sky, a vessel with a gross tonnage of 47,800, was delivered in 2017 to operator Viking Ocean Cruises.