Hundreds of thousands of revelers bundled in warm layers witnessed the coldest New Year’s Eve ball drop in 100 years at midnight Sunday, after clearing stepped-up security for blocks around iconic Times Square.

“Happy New Year!” shouted Mackenzie Johnson, 25, of Orlando, as she took a video of the glittering crystal ball’s descent marking the start of 2018. “All the confetti, everybody here, the crowd, the atmosphere. It was just a really cool experience!”

It definitely was a cold experience. As the crowd shouted the countdown of seconds, the mercury stood at 9 degrees in Central Park at midnight and it felt like minus 4 degrees — the most frigid New Year’s in Times Square since 1917, according to the National Weather Service.

That year, the Times Square temperature at midnight was 1 degree, making it the coldest ball drop on record, according to the weather service. Before Sunday night, the second-coldest was 11 degrees set in 1962.

The first New Year’s ball drop was in 1907.

Nina Izzo, 47, of Westbury, said it was worth enduring the cold temperatures to make the memory with her daughter.

“You live in New York, you have to experience it at least once,” she said.

Jason Quintanilla, 19, of Central Islip, said he had not seen the ball drop before in person. He pegged the cold at 9.5 on a scale of 1 to 10.

“I dressed warm, but not warm enough,” Quintanilla said.

City officials said they took unprecedented steps to protect the one million revelers expected to ring in 2018 in Times Square — moves sparked by recent terror attacks.

Scores of police officers were stationed in the blocks outside the secure area — with crowds as far south as 38th Street — as people huddled together, bounced up and down or walked in place for warmth.

Juliann Bohin, 31, of Ronkonkoma, said she doesn’t have any resolutions for 2018, but “this was on my bucket list. It was super exciting. 2017 was an awesome year and I’m ready for 2018.”

Many in the crowd took selfies, waved yellow and purple balloons and bought hats, horns and noisemakers from vendors. The mood was festive, especially for some first-comers to the ball drop, despite the frigid temperatures and high security.

“We always watch it on TV and we wondered what it was like to come here,” said Nayelis Figueroa, 10, of Cleveland.

Kenny Powell, 32, of Tennessee, said he and his wife got into the secure area at 6:30 p.m.

“It’s bittersweet, if you will,” he said. “It’s cold, but it’s a once-in-a-lifetime experience.”

Others traveled from outside the United States.

Linda Rodriguez, 31, and her boyfriend, Daniel Navarro, 43, are from Juarez, Mexico, and in Manhattan for the first time.

“Going to Times Square for New Year’s Eve is something we had to do,” Rodriguez said.

Daniele Germani, 27, of Milan, Italy, said he has been to Manhattan before but hoped to see the ball drop.

“It’s like a dream to be here,” he said.

Earlier, thousands of Phish fans attended the band’s concert at Madison Square Garden. Frank Abramson of Great Neck, waiting to board a Long Island Rail Road train home, said he is optimistic about 2018 because of his health and his children.

“What more do you need?” he said.

New York officials said there was no evidence that any terror group or lone wolves would attempt to disrupt the New Year’s Eve celebration. But the NYPD and other agencies did not take any chances.

Plainclothes officers, uniformed cops and K-9 units flooded the area, and revelers were screened twice before entering Times Square. Knapsacks, large bags and umbrellas were banned from the area, and purses and other bags were searched. In addition, radiation detectors were deployed and newspaper boxes and garbage cans removed.

Gov. Andrew M. Cuomo’s office said personnel from multiple agencies, including State Police, the National Guard, the Metropolitan Transportation Agency and the Port Authority, were bolstering security at bridges, tunnels, airports, transit hubs and other high-profile locations.

Some partiers weren’t worried, though they appreciated the extra security.

“It is something that has happened, but we have to live our lives,” Rodriguez said.

The beefed-up security came just 20 days after police say an Islamic State group-inspired native of Bangladesh injured himself and five others after he set off a pipe bomb on Dec. 11 underneath the Port Authority bus terminal, just a few blocks from Times Square.

In a separate case, an Uzbek national was arrested and accused of killing eight people after he drove a rental truck onto a bike path along the West Side Highway on Oct. 31.

With Michael O’Keeffe and Stefanie Dazio