PORTLAND, Maine — A man is being treated for hypothermia after he spent at least five minutes in the ocean after being knocked off a pier into Portland’s Casco Bay during Saturday’s historic storm, according to officials.

The man, whose boat was docked at the pier, fell into the ocean a few minutes before 3 a.m. on Saturday as the blizzard was at its peak, Portland Fire Chief Jerome Lamoria told the BDN.

It’s unclear whether the man was blown in by the wind or slipped on the snow-covered pier, Lamoria said. At the time, there were wind gusts up to and over 50 mph and 2- to 3-foot waves.

“It was a very hairy situation,” Lamoria said. “I was afraid one of the firemen was going to go over, too.”

The area contains boats that people live on, according to Lamoria, though he did not know what purpose the man’s boat was for.

“A person staying on a boat heard him when he fell in and ran for help,” Lamoria said. The dockmaster for Dimillo’s made the 911 phone call.

When the fire department arrived, bystanders were pulling the man up onto the float. Responders put him onto a stretcher and transported him to the hospital in serious condition.

The rescue involved three fire companies and a medical crew.

Check bangordailynews.com for updates