A BYU grad/engineer/inventor, frustrated about packages being stolen off his porch, came up with an “over-engineered monstrosity” — a fake package that explodes with glitter and sprays fart smells on the thieves.

He’s gotten more than 37 million views on YouTube with his video about the device as of Thursday morning.

Mark Rober, who graduated from Brigham Young University with a degree in mechanical engineering, got a master’s degree from USC and spent nine years working at NASA’s Jet Propulsion Laboratory, says in the video that he “felt sort of violated” when he realized a package had been swiped from his porch.

His security cameras caught the thief in the act. “I took this to the police, and even with the video evidence, they said it’s just not worth their time to look into.” That left Rober feeling “powerless.”

“I just felt like something needs to be done to take a stand against dishonest punks like this,” he says. “And then I was, like, hold up! I built a dartboard that moves to get a bull’s-eye every time. I spent nine years designing hardware that’s currently roving around on another freaking planet.”

(He worked on the Curiosity rover, which is now on Mars.)

“If anyone … was going to make a revenge fake package and over-engineer the crap out of it, it was going to be me.”

With help from a friend, Rober spent six months designing and creating a device that, when the box is opened, shoots glitter everywhere and releases fart spray.

It includes four phones that take video that is uploaded and GPS that allows Rober to retrieve the package when the thieves toss it out of their car … which happens repeatedly.

“So the moral of the story is — just don’t take other people’s stuff,” Rober says in the video. “Not only is it not cool, but on the plus side, you’ll never find yourself in this situation.”

Rober, 38, is no YouTube novice. He also hosted a short-lived show on the Science Channel, has appeared on “Jimmy Kimmel Live” and founded Digital Dudz (which he sold, but remains as chief creative officer).

Not only is his glitter-bomb video racking up millions of views, but there’s demand out there for it.

“This needs to be sold in [a] store,” wrote one commenter.

“I would buy this product for a lot of money.”

“Sell it on Amazon. I would totally buy this.”

Rober blurs the faces of the thieves in the 10-minute video and bleeps out their curses. The video has gotten almost half a million likes on YouTube, but, judging by the comments, a lot of people would like it even more if the glitter bomb had been more damaging. Even lethal.