“The Gray Man” is so ambitious that its faults are worth overlooking. Indeed, for every nit to pick here, there’s a moment to admire.

This spooky story finds Simon, an anxious and lonely young man in New York City in 1910, recovering from the recent death of his overbearing mother. Her protectiveness was smothering, yet it safeguarded him from a ghostly presence: the fiend of the title, who we’re told leads children to their deaths, or to madness.

Neighborhood youths soon start to disappear. Simon’s sudden desire to leave the city, and the random arrivals and departures of his shady friend, John, create a mystery that casts suspicion on everyone.

The fablelike script, by Andrew Farmer, is steeped in gothic storytelling and moodiness. That’s fascinating. The tale is occasionally reminiscent of “The Woman in Black” and “The Pillowman.” But unlike those plays, it offers little humor to vary an unceasingly grim tone. That’s problematic. You’ll also probably guess most of the ending before it arrives.

Plot concerns aside, the production values are exceptional. Shadows, tinkling piano music and other effects create an immersive sense of menace for this show, which is performed in the round and runs under 90 minutes. There are long scenes staged in complete darkness or with only a trace of light. If you’re uncomfortable in a pitch-black room, you’ll need to pass up this play.

Daniel Johnsen, as Simon, displays a confusion and fear that are contagious. Shane Zeigler, as John, made me nervous in just the right way. (It’s a nice contrast to his role in the rollicking 2013 comedy “Clown Bar,” which was directed by Andrew Neisler for the Pipeline Theater Company, as this show is.) Katharine Lorraine and Claire Rothrock, in supporting parts, have near-perfect timing. Tahlia Ellie, an 11-year-old actress making her New York debut, is impressive.

Those lightless scenes and morbid stories are quite risky to attempt in front of an audience. True, if you read a lot of mysteries, you’ll probably find “The Gray Man” somewhat stereotypical and often stuck on a single note. Yet if you see a lot of theater, you’ll admire all the chances it takes.