Sarah, Duchess of York has landed a book deal with romantic fiction publisher Mills & Boon, admitting she "drew on many parallels from my life" for the historical tale.
Her debut novel is called Her Heart For A Compass and will be released in the summer. It tells a fictional account of the life and love story of the duchess's great-great-aunt Lady Margaret Montagu Douglas Scott.
Mills & Boon describes it as an "immersive historical saga" that "sweeps the reader from the drawing rooms of Victoria's court and the grand country houses of Scotland and Ireland, to the slums of London and the mercantile bustle of 1870s New York".
It follows Lady Margaret "who desires to break the mould, follow her internal compass - her heart - and discover her raison d'etre - falling in love along the way".
Sarah revealed she came across Lady Margaret after researching her ancestry and became fascinated because Margaret is her middle name.
She told how she took inspiration from her own experiences when writing the work.
The duchess was pictured in a Victorian-style floor-length outfit, complete with high-necked blouse, jacket and gloves, sat on a stone bench gazing at a compass, to promote the work.
She said: "Although her parents, the Duke and Duchess of Buccleuch were close friends with Queen Victoria and Prince Albert, I was unable to discover much about my namesake's early life, and so was born the idea which became Her Heart For A Compass.
"With real historical events and facts to hand, my imagination took over. I invented a history for her that incorporated real people and events, including some of my other ancestors.
"I created a friendship between my heroine and Princess Louise, Queen Victoria's sixth child, and I drew on many parallels from my life for Lady Margaret's journey."
The duchess, who has previously written her memoirs, is the author of numerous children's books including the Little Red and Budgie the Little Helicopter series, and was an executive producer of the 2009 historical film The Young Victoria.
She wrote the book with author Marguerite Kaye, who is described as her "collaborator and mentor".