NEXT spring, Susie Boyt will slip on her metaphorical ruby slippers, hire a bus, fill it with family and friends, and head for Nottingham, where a musical based on her brilliant memoir, My Judy Garland Life, is to be staged.

"My life is a musical," marvels the 43-year-old great-granddaughter of Sigmund Freud. We agree that you could not make it up. And yet it seems singularly appropriate because London-born Boyt's affecting book – "one part memoir, two parts hero-worship and three parts biography with a dash of sequin- studded self-help thrown in" – is written in prose that sings from the heart and dances with joy.

Boyt, the youngest of five children her mother, Suzy Boyt, had with the late Lucian Freud (she also has 10 half-siblings from her father's multitudinous love affairs) is a gifted writer, like her sister Rose and half-sister Esther Freud. She has written four novels, as well as the memoir. Indeed, she wrote her first collection of poems when she was nine, "almost all on the subject of disasters narrowly avoided".

About to publish her fifth novel, the tragi-comic The Small Hours, an examination of love and the lack of it, she sends me a note saying, "I am a little bit excited". She has every right to be, because she has written a divinely dark book.

"Divinely dark! It sounds like a gorgeous chocolate pudding – which is fine by me!" says Boyt, whose thoughtful grey eyes and fine bone structure bear the imprint of her famous father's elegant features. In particular she has inherited his thin nose and mysterious mouth, hinting at secrets never to be revealed, although she did share with him a love of food, good books and bad puns. He painted at least three portraits of her: she first sat for him when she was 16. For his 80th birthday, she baked him a huge cake iced with one of his nude self-portraits.

Actually, the baking analogy is apt. When it comes to cakes, Boyt – whose third novel, The Last Hope Of Girls (2001), was shortlisted for the John Llewellyn Rhys Prize – believes that "heartening comestibles" can make life worth living. However, she knows her Mary Berry from her John Berryman, the American poet who, with Henry James, was the subject of her MA thesis at University College, London. (In her new book there's a frighteningly funny scene involving six pounds of almond paste.)

The Small Hours is an investigation into the very best and the worst of how we treat each other. It's the darkest novel she's ever written, her first since Only Human (2006). The Small Hours was originally called The Nursery; it would be a cross between The Nanny Diaries and The Turn Of The Screw, Boyt once told me.

"Do you think I've succeeded? That sounds a bit flippant now," she suggests as we talk over coffee in a Covent Garden cafe. Boyt, who has two daughters, Mary (11) and Cecilia (6), with her film producer husband Tom Astor, has been "a little bit obsessed" with Henry James and his world, ever since she read him as a student at Oxford University. There she became intrigued by the Jamesian question of how one can be good and live fully in the world without taking on any of the taint that the word "worldly" creates – a constant theme in her work.

Before she began writing The Small Hours, she'd been re-reading James's The Bostonians and was very taken with the idea of "a very strong, large female character who rubs people up the wrong way and who probably talks a lot of sense but isn't listened to in life. Of course, there was another challenge: how do you find a heroine who can compete with Judy Garland?"

Another influence was James's sister Alice's diaries of her final years, "which are pretty bonkers, because she was quite unhinged, although just as clever as her two brothers. Actually, I'm always thinking about James's characters. Until recently, I belonged to a Henry James support group – a book group that only read his books. At Christmas, in a slightly excruciating way, we'd act out one of the stories. I was Mrs Bread, the housekeeper who's no better than she ought to be."

When we first encounter Boyt's brilliant but damaged heroine Harriet Mansfield, she is 38-and-a-half-years-old – "a red-haired, earthbound woman of six foot one, serious-hearted, not given to literal flights of fancy, intense rather than intrepid ..." The Small Hours begins with Harriet's final appointment with her Kleinian analyst. Why not a Freudian? "Well, most Freudians are now quite Kleinian," responds Boyt, who firmly believes in the power of psychoanalysis to transform lives.

The story shifts between past, present and future as the Brodie-esque Harriet opens a private nursery school for girls "to try to give herself the childhood she never had". Harriet tells her therapist: "I want to make a sort of paradise for the children... I think I am going to make the school almost too lovely." And indeed she does; then things turn ugly.

The narrative, Boyt explains, is fraught, but she hopes that it's equally filled with delights and despair. "I've developed a good line about this book. Yes, it's sad, but not relentless!

"I got the idea when I was looking for schools with my daughter Mary. One headmistress made a speech I quite liked but she said something that didn't sit right with me. I didn't challenge her, just asked her to explain. Quick as a flash she said, 'I only want you here if you love me and you love my school.' I thought, 'Wow! This is a place where feelings could not possibly run any higher'. Just based on that comment I wondered what would make someone say that, to be so incredibly defensive, to be so if-you're-not-with-me-you're-against-me? Was it something about the nursery school environment? I also wondered if any criticism was completely unbearable to her.

"I started thinking about why that person might have gone into early years education and if she was someone who was brilliant with little children but not with adults. And what is it that makes people have this tremendous compassion for little children? Generally, it's because they're identifying with the children in some way. In my fantasy, she was making up for something in her own childhood that had gone wrong."

Boyt pauses and says: "I think some people go into teaching because they really want to be in the right all the time." Nonetheless, she believes she owes a great deal to two wonderful English teachers at Camden School for Girls, who encouraged and inspired her. "I still think about them often," she has written.

A blue-stocking and a fashionista, she's always beautifully dressed. Today she's in navy blue and charcoal grey cashmere – a sort of sexy school uniform but for her vertigo-inducing navy blue and cream platform-soled Castaner wedges. She giggles that she actually toppled off them on her way to meet me from her north London home.

Clothes are clearly part of Boyt's emotional armour. Since 2003 she's written a column, "about the morality of glamour and the ethics of aesthetics," although lately it's more about life in general and particular. "I wanted to make it funnier," she confides, explaining that life had been hard. Her father died at the age of 88 in July last year; then her "heroic" mother became unwell. "Oddly, I was writing scenes in The Small Hours about Harriet visiting her mother in hospital; then a few months later I was doing just that."

But then life often imitates art, she has found. A trained bereavement counsellor for the charity Cruse, she became interested in their work after they counselled her through her grief following the death of her boyfriend in an accidental fall when they were students at Oxford. "To be fully present for the person in distress is often the greatest thing you can offer," she once told me. In any case, people are forever confiding in her. Strangers tell her their life story. Counselling taught her to listen – a gift for a novelist.

"From childhood I fancied myself as a bit of an agony aunt – an old head on young shoulders. I do like to know what people think; I just like people. But I've stopped giving advice," she laughs.

As to the obsessive media interest in the glamorous Freud dynasty, she understands it but will never write about her father. "None of us gave any interviews after he died. We discussed writing about him but decided against it," she says.

Searching Boyt's books for autobiographical material is pointless, although many insist on so doing. "I actually do make it all up!" she exclaims. So why not, as her friend, the psychoanalyst Darian Leader, has suggested, see what Boyt's books can illuminate about yourself rather than the author?

The Small Hours by Susie Boyt is published by Virago, £15.99