As profiled in the documentary “An Honest Liar,” skeptic James Randi exposes frauds while keeping a few of his own secrets. (Abramorama)

At barely more than five feet tall, and with a bushy white beard and beetled brow, magician James “The Amazing” Randi resembles nothing so much as an angry elf. Both sides of this persona — a mischievous, convention-flouting twinkle and an unwillingness to suffer fools and charlatans — come across in Tyler Measom and Justin Weinstein’s affectionate and informative documentary portrait, “An Honest Liar.”

Born in Toronto as Randall James Hamilton Zwinge, Randi worked for many years as a successful magician before becoming better known in the 1970s for his crusade to debunk such claims of paranormal powers as those made by Uri Geller. Geller, an Israeli-born “psychic,” became a celebrity for his appearances on American television in which he presented himself as being able to bend spoons and other metal objects with his mind. A 1986 MacArthur “genius” grant recipient, Randi had written a 1982 expose, “The Truth About Uri Geller,” and was famous for exposing such fraudulent faith healers as Peter Popoff, a televangelist who used a hidden earpiece to enhance his so-called clairvoyant abilities, raking in millions of dollars in contributions.

Through archival footage and interviews with such friends and magician colleagues as Penn Jillette and Jamy Ian Swiss (the latter of whom is also featured, coincidentally, in the excellent “Merchants of Doubt” documentary), the film covers the milestones of Randi’s career in a manner that is both thorough and entertaining.

But it is when they arrive at one particular highlight of Randi’s personal life — his decision to come out publicly as gay, at the age of 81, in 2010 — that the film really gets interesting. It’s not so much for the titillation factor as it is for a twist that has to do with Randi’s relationship with his longtime partner, a man first introduced in the documentary as José Alvarez.

You can Google Alvarez, an artist who has worked as Randi’s assistant and who once famously masqueraded as a channeler of spirits in order to expose such charlatanism. But it’s better, I think, to just let the film tell his meandering tale in its own sweet time.

It’s good not to say too much more, so I won’t.

I will say this: The relationship between Randi and Alvarez is a sweet one, even though at its heart lies something of a deception. (That’s no spoiler; one of the interview subjects says as much, early in the film.) But the kink in the narrative lends “An Honest Liar” a level of depth that enriches and complicates its message.

In the end, “An Honest Liar” becomes a far more layered tale than it starts out to be. Professionally, Randi’s life, both as a magician and as a debunker, has always been about lying to reveal a greater truth: We get fooled again and again because we want (or perhaps even need) to be deceived. But the film also argues that, on a personal level, Randi’s legerdemain — his playing fast and loose with a fact or two — has only ever been in the service of love, not larceny.

Unrated. At Landmark’s E Street Cinema. Contains brief obscenity. 92 minutes.