Leonard Cohen’s final album, “You Want It Darker,” is icicles bathed in moonlight, a breathtakingly beautiful album that’s as painful as it is compelling. Mind, this is a normal state of affairs for a Cohen album. To steal a joke, Cohen is like whiskey: A little is great, a lot leaves you messed up and weeping.

But this one — released just before Halloween, when the days shorten and the shadows seem to engulf everything — seems to be the distilled essence of his music. It doesn’t help listening to it after his death, which came at the end of an emotional election week. “You want it darker,” sings Cohen, on the album’s title track. “We kill the flame.”

Much like David Bowie’s final album, “Blackstar,” a sense of finality haunts every corner of the music. The second song, “Treaty,” which refrains at the end, has Cohen — an observant Jew who is also a Buddhist monk — wrestling with the idea of Jesus near the end of his life: “I wish there was a treaty we could sign/I do not care who takes this bloody hill/I’m angry and I’m tired all the time/I wish there was a treaty … Between your love and mine.”

The song is replete with anguish, conveyed through Cohen’s expressive, cracked gravel voice. Like much of Cohen’s work, it’s so emotionally and intellectually complex that you find new layers each time you return, but in the end, it’s about dying, God and what those things mean at the body’s twilight, how even a spiritual person can be wracked with doubt.

Like another of 2016’s great musical losses, Prince, it’s sometimes difficult to parse whether Cohen is singing about religion or romance. In “On the Level,” he sings: “When I walked away from you/I turned my back on the devil/Turned my back on the angel too.” In “If I Didn’t Have Your Love,” the piano takes on the aspect of church organ, and it’s unclear if the song’s addressed to a person or to God. And as is the case with Prince, there’s a power in the fact that these songs work on both levels.

“If the sun would lose its light,” he sings, “And we lived an endless night/And there was nothing left/That you could feel/That’s how it would be/My life would seem to me/If I didn’t have your love/To make it real.”

The sense of impending death that permeates the album gives everything an almost desperate urgency, even as Cohen himself remains calm and meditative. Famously, Cohen’s vocals are more spoken than sung, but the smokiness and steadiness in his voice here lend the music a great deal of tension. When he reaches the song “Traveling Light,” which is more overtly about dying, there is almost a sparkle in his voice: “I’m running late,” he sings, “They’ll close the bar/I used to play/One mean guitar.”

For all his heaviness, Cohen manages to laugh at the end. God and death are serious business, but there’s still room for a joke. It’s highly appreciated, especially as the album returns to Cohen’s fascination with Christianity in “It Seemed the Better Way”: “First he touched on love,” he sings, “Then he touched on death/Sounded like the truth/Seemed the better way/Sounded like the truth/But it’s not the truth today.”

“You Want It Darker” is, in the end, about looking out at the Great Unknown and realizing the difference between what you believe and what you wish to believe, and how, when you’re alone with nothing but the truth, the difference between those things is insurmountable. In a lot of ways, it’s a perfect capstone for an artist whose catalog has been filled with songs that radiate regret, that have featured personas who wrestle with love and beauty, and how they slip through one’s fingers like water. Cohen’s legacy of gorgeously wrought songs — “Everybody Knows,” “First We Take Manhattan,” “Suzanne,” “Tower of Song,” “So Long Marianne,” “Bird on a Wire” and perhaps mostly famously “Hallelujah,” to name just a few — have always been filled with a sort of restlessness, a sense of trying to fill a void. Whether it be in love or religion, there was always a sense of his longing for something beyond what he had, no matter how destructive that urge might be to both himself and others.

“I did my best, it wasn't much,” he sings, in “Hallelujah,” “I couldn't feel, so I tried to touch/I've told the truth, I didn't come to fool you/And even though it all went wrong/I'll stand before the Lord of Song/With nothing on my tongue but Hallelujah.”

And in the end, that’s where Cohen’s musical journey ends: With all the wanderlust abated, and with an acceptance of his own truth.

“I wish there was a treaty we could sign,” he sings at the end. “It's over now, the water and the wine/We were broken then but now we're borderline/And I wish there was a treaty/I wish there was a treaty between your love and mine.”

Email Victor D. Infante at Victor.Infante@Telegram.com and follow him on Twitter @ocvictor.