The keyword in all the advance talk about Terrence Malick’s “A Hidden Life” was linear. The film, which premiered at the Cannes Film Festival in May, was supposed to mark the reclusive but prolific director’s return to script-based filmmaking after years spent working in an improvisational, ruminative style; it was billed as Malick telling a story again rather than Malick indulging in his occasionally glorious, occasionally perplexing flights of fancy.

Of course, linear is a relative term when it comes to Terrence Malick. “A Hidden Life” is anchored in story in a way the director’s last few films have not been, but its storytelling rhythms are quintessentially his, with all the beauty and all the languor that that entails.

Based on the true story of an Austrian conscientious objector who refused to fight for Nazi Germany in World War II, “A Hidden Life” is certainly the director’s best movie since his 2011 Palme d’Or winner “The Tree of Life” — it’s his most monumental film since then, and perhaps his most sentimental film ever. And it is also slow and meditative, requiring viewers to sink into and surrender to that particular Malick style that some find maddening.

Also Read: 'A Hidden Life' Stars Valerie Pachner and August Diehl on the Full Immersion of a Terrence Malick Film | Video

It may well be seen as the movie where Malick gets his mojo back, though that could be an unfair characterization of a man who has remained a fascinating filmmaker over the eight curious years since “The Tree of Life.” He’s made more movies in that stretch than any similar period of his career, but gotten less acclaim for them. After creating a meditative, rapturous template with “Tree of Life” — improvisation-based, full of whispered asides and fragments of conversation — he went all the way down that rabbit hole with “To the Wonder” and “Knight of Cups,” with increasingly frustrating results for those who want more than gorgeous images and narrative conundrums.

But “Voyage of Time,” his 2016 “documentary” on, essentially, the creation of the universe, was both ravishing and richly ruminative, particularly in the extended, Cate Blanchett-narrated version rather than the shorter, Brad Pitt-narrated “Malick for kids” IMAX version. The following year’s “Song to Song” went back to the earlier template, but the music provided a narrative spine that produced one of his most satisfying recent films, even if it fell well short of the grandeur of “Tree of Life.”

And now comes “A Hidden Life,” which lets us know we’re in Terrence Malick territory from the start. There’s a black screen, the sounds of nature — wind, running water — and a soft voiceover: “I thought that we could build our nest high up in the trees,” a male voice says. “Fly away like birds.” We see shots of bucolic vistas high in the Austrian Alps, and then the choral grandeur of Bach’s “St. Matthew Passion” comes in to make it crystal clear whose movie this is.

But there is a strong narrative here, and it’s the true story of Franz Jägerstätter, an Austrian farmer from the small village of Radegund. When Nazi Germany annexed Austria in 1938, Jägerstätter reported for military duty but refused to swear the required oath to Adolf Hitler or to fight in what he considered an unjust war. He was imprisoned, sentenced to death and executed in the summer of 1943; his sentence was nullified by a Berlin court in 1997, and he was declared a martyr and beatified by the Roman Catholic Church in 2007.

But those later developments aren’t covered in the film, and Malick isn’t one to use end-credit updates, even in movies based on real events. Instead, “A Hidden Life” sinks into a few years of Jägerstätter’s life, from 1938 until his death. The first half of the three-hour film is pastoral and languid, exploring the relationship between Jägerstätter (August Diehl) and his wife Franziska (Valerie Pachner) in a style that will be familiar to Malick aficionados: glances, snippets of conversations, playful moments in the long grass and occasional voiceovers.

But the talk is less fragmentary than in the past few Malick films. Seeing the rising influence of the Nazis, including some vitriolic anti-immigrant talk from the town’s mayor, Jägerstätter consults a bishop about the idea of refusing to serve, arguing, “We’re killing innocent people, invading other countries.” But the clergyman, mindful of who’s in charge and what resistance would bring, is unmoved: “You have a duty to the fatherland,” he says. “The church tells you so.”

Also Read: 'Hidden Life' Stars on Working on Terrence Malick's Film With 'No Breaks' (Exclusive Video)

There is real majesty in Malick’s images here, whether they’re images of beauty or of a growing mania and darkness. “Is this year the end of the world?” an older villager asks at one point. “Is it the death of light?”

Malick drops in flashes of historical footage that suggest things might have been heading for just that, but mostly he sticks to his particular style of cinematic poetry — even when the film moves into its darker and grittier second half, when Jägerstätter is imprisoned and we cut between his days in jail and his wife’s struggle to survive in a village that has ostracized her.

This stretch becomes an extended crisis of conscience, as person after person entreats Jägerstätter to take the loyalty oath and accept a non-combat job. The appeal is the same: How will this change anything, and who are you helping by doing this?

The answer for Jägerstätter is clear: I’m helping me live with myself. His position never changes, and this section of the film is where the deliberate discursive rhythms of Malick’s storytelling can be wearying. This is also where the film becomes most reliant on voiceover, with the story carried along by the reading of letters between Jägerstätter and his wife.

In this stretch, Franziska is in many ways as central a character as her husband, with Pachner and Diehl well matched; they’re why the film feels as sentimental as anything Malick has done (which, whatever the implications of the word sentimental, is not a complaint). James Newton Howard’s score is appropriately grand — though as usual for Malick, it’s abetted by the extensive use of existing classical music, from Bach and Beethoven and Handel to Henry Gorecki, Arvo Pärt and Alfred Schnittke.

As a World War II story, “A Hidden Life” has none of the visceral nature of Malick’s “The Thin Red Line,” but it’s not meant to. This is part love story, part tragedy and part meditation on faith and conscience — and it’s wholly Malick in a way that is closer to “The New World” and “The Tree of Life” than his films since then.

Frustrating at times but beautiful far more often, “A Hidden Life” is a luminous and substantial addition to a singular filmography.