The writer and director Bryan Forbes, whose films included Whistle Down the Wind and 1970s horror classic The Stepford Wives, has died aged 86 following a long illness, a family friend has said.

Forbes, who began his career in film as an actor and screenwriter and became one of the most important figures in the British film industry, died surrounded by his family at his home in Virginia Water, Surrey, friend Matthew D'Ancona said.

He was married to actor Nanette Newman, who appeared in several of his films, and with whom he had two daughters – the TV presenter Emma Forbes and the journalist Sarah Standing.

D'Ancona said: "Bryan Forbes was a titan of cinema, known and loved by people around the world in the film and theatre industries and known in other fields including politics. He is simply irreplaceable and it is wholly apt that he died surrounded by his family."

Forbes, who was made CBE in 2004 for services to the arts and the National Youth Theatre of Great Britain, was born John Theobald Clarke in Stratford, London in 1926. He began acting in the late 1940s after changing his professional name, playing a number of supporting roles in notable British films including An Inspector Calls and The Colditz Story. But he soon became better known as a screenwriter and director.

His notable screenwriting credits included I Was Monty's Double (1958) and The League of Gentlemen (1959), about a group of former army officers who use their wartime skills to plan a daring bank robbery.

His directing debut was the acclaimed Whistle Down the Wind (1961), about three Lancashire children who believe a criminal they discover hiding in their barn is a reincarnation of Christ.

In 1969 Forbes became chief of production and managing director of film studio Associated British. Although the venture produced a few classics, including The Railway Children (1970) and The Go-Between (1970), many other projects were either disappointments or were frustrated due to financial problems and Forbes resigned in 1971.

But Forbes had enjoyed success in Hollywood in 1965 with the film King Rat, a prisoner of war drama, and 10 years later he returned to the US and directed The Stepford Wives (1975), based on the novel by Ira Levin.

In his later years, Forbes turned to writing novels, including his latest, The Soldier's Story, published last year, and two volumes of autobiography.

He was awarded the Dilys Powell award for outstanding contribution to cinema at the London Film Critics' Circle Awards in 2006.

Interviewed by the Daily Mail last June, Forbes said he was diagnosed with multiple sclerosis in 1975 but doctors later told him it was a misdiagnosis.