Hundreds Hall is the name of a grand pile of brick in Warwickshire, England, and if you’re moderately familiar with movies and television — “Downton Abbey,” “Crimson Peak,” the “Ghostbusters” reboot — you have no doubt seen hundreds like it. Its sprawling grounds and cavernous rooms evoke ancient aristocratic privilege, but by the late 1940s, when “The Little Stranger” takes place, that grandeur has begun to fade.

Dr. Faraday — we never seem to catch his first name — remembers it well. An ambitious provincial physician whose mother worked as a maid during the house’s glory days under the Ayres family, he looks back fondly on a summer day he spent there in 1919, when he was 8 years old and local commoners were invited to a fair. Now he finds himself treating the remaining members of the Ayreses, who are barely hanging onto their fast-decaying ancestral home.

Faraday (Domhnall Gleeson) is haunted by Hundreds Hall. The Hall itself also seems to be haunted, though it’s not always clear by what or whom. The best guess seems to be a little girl named Suki Ayres, who died shortly after Faraday’s long-ago visit. Her mother (Charlotte Rampling) still lives there, along with her two surviving, grown-up children: Roderick (Will Poulter), who was badly wounded in World War II, and Caroline (Ruth Wilson), “the cleverest of the lot” (according to a family friend), who drifts toward eccentric spinsterhood. The staff has been winnowed to one, a young woman named Betty (Liv Hill), who figures out that something creepy is going on long before anyone else seems to have a clue.

Directed by Lenny Abrahamson (“Room”) and adapted by Lucinda Coxon from Sarah Waters’s skillfully written Gothic novel, “The Little Stranger” is for much of its running time more interested in the sociological and psychological implications of Faraday’s encounter with the Ayreses and their real estate than with any overtly supernatural doings. Faraday, who serves as a possibly unreliable voice-over narrator, is buttoned up as tight as a waistcoat, only sometimes betraying the ruthless effort that his sang-froid requires. He is always aware of being an interloper — a commoner promoted to “one of us” ironically or in emergencies — and his attempts to fit in make this strangeness more glaring.

Mr. Gleeson is adept at this double game. His face is as sharp as a hawk’s but somehow also as soft and unformed as a fledgling sparrow’s. Faraday makes a practice of keeping all feeling in check, presenting himself both as a rational man of science and as the possessor of an exemplary stiff upper lip. As news of the political weather buzzes in the background — the advent of the National Health Service; land sales and tax policies promoted by Clement Attlee’s Labour government — Faraday mourns the waning of old ruling-class prerogatives more plangently than the Ayreses themselves, who would seem to have more to lose. His loyalty to them is more than they deserve or desire.

The twisting and cracking of the British class system is always fascinating to observe, and “The Little Stranger” traces the details of its chosen moment of social change with precision and subtlety, and with its own layers of somewhat dubious nostalgia. Since it’s also a horror movie, subtlety can go only go so far, and the past becomes a trunk mined for spooky costumes and effects. There are a few jump scares and shocking images, but Mr. Abrahamson lets the dread build slowly, nudged along by Stephen Rennicks’s mournful, eerie score and Ole Bratt Birkeland’s brown-shadowed cinematography.

As Faraday draws closer to the Ayreses, a question starts to percolate. Are they just odd and miserable, or is something more sinister afoot? Poor Roderick, inwardly and outwardly maimed by the war, teeters floridly toward madness and alcoholism, but what about Caroline and her mother? Are they sheltering a sinister secret? And what does the specter of Suki want — if that is indeed what rattles the door frames and carves squiggles in the wainscoting.

As is usually the case in movies like this, the answer is not quite as intriguing as the queasy guesswork that precedes its revelation. But the ending is less of a letdown than it might have been, and the final shots are potent and provocative, sending you back over what came before with new ideas and questions. The twist has less to do with who is haunting whom than with spectral methods and motives, and with the fantasies of belonging that dwell within Hundreds Hall’s walls.

The Little Stranger
Rated R. I say, old chap: boo. Running time: 1 hour 51 minutes.