Jeffrey Samuels QC, defending Levi Bellfield, who is accused of murdering Milly, asked Mr Dowler whether she was really the “happy go lucky” girl who had been portrayed in the media.

“She had her demons, did she not?” asked the barrister. Mr Dowler replied: “I think she had natural childhood fears.”

Mr Dowler, 59, came to the attention of police after admitting that he lied to them about his movements on the day his daughter disappeared in March 2002.

He insisted at the start of the trial that he had nothing to do with her abduction or death.

Milly was 13 when she vanished as she walked home from school in Walton-on-Thames, Surrey. Her body was found in woodland six months later.

Bellfield, a convicted double murderer, has been found guilty of her abduction and murder.

Mr Dowler’s secret sexual life and the police’s interest in him emerged as he was cross examined by Mr Samuels.

Surrey Police told him he was a suspect “whether he liked it or not” and interviewed him three times, the court heard.

Mr Samuels said: “Is it right that you became for a time the focus of police inquiries?”

“That is correct,” replied Mr Dowler. “I was very concerned because I knew they needed to be focused on someone else.”

The jury was told that Milly had found pornographic material at the bottom of a chest of drawers in her parents’ bedroom months before she disappeared.

She was searching for clothes when the drawer fell out and she saw the fetish-themed pornography underneath it.

She told her mother, Sally, about what she had found, and seemed quite “taken aback”, the court heard.

Mrs Dowler, 51, said she tried to comfort her daughter when the teenager discovered the pornographic magazine: “I said to her 'it doesn’t mean daddy doesn’t love me.’”

In another note found in a drawer in her room, Milly wrote: “Jess is a true friend. She is the best. Jess helped me the most with this whole dad thing.”

Mr Dowler said he could only think that this referred to her discovering the adult magazine. However, he insisted that his relationship with his daughter had not been affected, and on the day she went missing she kissed him as normal.

“She made a specific point of always kissing me goodbye,’ he said.

Mr Dowler, who arrived home early from work the day his daughter vanished, spoke to her at 3.45pm in what he described as a “totally normal conversation”. What he did not initially tell police was that he had stopped to view pornography at a motorway service station before getting home shortly after 3pm and carrying out a sex act on himself.

The jury heard excerpts from an interview Mr Dowler gave to police in 2002 in which he was asked if he was in “any way responsible” for Milly’s disappearance.

He said: “The only way I can be responsible is if she had seen some of this material and decided to run away. God forbid she decided to take her own life or run away. I have no other involvement in any other way.”

Mr Dowler told the court that he had kept further “extreme” material in a desk in the hallway and in the sitting room. He also disclosed that there was bondage material in a box in the loft, including a rubber hood and a ball-shaped gag.

Mr Dowler told police about the items when they searched the house. Asked about the reaction of his wife, who knew nothing of the material, he said: “Distressed is hardly the right word.”