A Danish tourist on a school trip was robbed at knifepoint by two thugs who snatched his “Make America Great Again” cap — and threatened him when he tried to get it back, authorities said.

Jannich Andersen, 18, was about to jump on the subway at Union Square about 5:40 p.m. Thursday when one of the two robbers confronted him.

“He asked if I knew what it symbolized, and said I couldn’t leave with the hat,” Andersen told the Post in a Facebook message. “He was clearly offended.”

Then, he swiped the polarizing cap off the unsuspecting tourist’s head.

Andersen said he struggled with the robber and managed to get the hat back at first — but not for long.

“I tried to walk away, and then he followed me and grabbed it again, and we just [stood] there both holding the hat,” he recalled. “Then one of my friends told me one of the [robber’s] friends had a knife.”

At that point, Andersen started to panic.

“I began to shake, and as I heard the word knife I let the hat go,” he said.

Andersen said he bought the hat in New York — but never thought it would make him the victim of a crime.

“I bought it for my dad as a joke,” he said. “I don’t know why I decided to wear it. I didn’t think some people would take it so far to [try to] stab a tourist over a hat.”

Andersen, who was visiting the city for the first time, said he would like to return, “but not with that kind of headwear ever again.”

Police released a sketch of one of the suspects, who was described as being an almost bald, 6-foot-tall white man in his 20s or 30s, with light facial hair.

He was last seen wearing a tan or brown jacket, dark pants and a baseball cap.

The second suspect was described only as a male white.

Anyone with information is asked to call the NYPD’s Crime Stoppers Hotline at 1-800-577-TIPS (8477) or for Spanish, 1-888-57-PISTA (74782).