This is probably not the best trick to teach your dog.

A British man named Markus Meechan, 28, wound up behind bars after a video emerged of his dog doing a Nazi salute when hearing the phrase "Sieg Heil" and jumping up when hearing the words "gas the Jews."

The pooch, named Buddha, is also seen watching footage of Hitler on a computer.

Meechan was arrested on suspicion of a hate crime. Buddha belongs to Meechan's girlfriend.

Meechan, who says he has a dark sense of humor, made another video in which he apologized and claimed he's not anti-Semitic. He said he merely made the clip to annoy his girlfriend and provide a laugh or two for his friends. He's also quoted as saying, "I am so sorry to the Jewish community for any offence I have caused them. This was never my intention and I apologize."

His girlfriend -- yes, they're still together -- also echoed his sentiment that he is not a racist in any capacity.