The Duke of York has "categorically" denied having any sexual contact with an American woman, who says she was forced to have sex with him aged 17.
Answering questions about his links to convicted sex offender Jeffrey Epstein in a BBC interview, Prince Andrew said the alleged incidents "never happened".
Virginia Giuffre, one of Epstein's accusers, claimed she was forced to have sex with the prince three times.
The prince said he was at home with his children on one of the occasions.
Prince Andrew, who is the Queen's third child, has been facing questions for several months over his ties to Epstein - an American financier who, at the age of 66, took his own life while awaiting trial on sex-trafficking charges.
Virginia Giuffre - then called Virginia Roberts - has said she was forced to have sex with Prince Andrew between 2001 - when she was 17 - and 2002, in London, New York and Epstein's private island in the US Virgin Islands.
Speaking to BBC Newsnight's Emily Maitlis, the prince said: "It didn't happen. I can absolutely categorically tell you it never happened."
"I have no recollection of ever meeting this lady, none whatsoever."
He said Ms Giuffre's account of him "profusely sweating" and "pouring with perspiration" when they danced at the club on the night in 2001 when she says they first had sex was impossible, because he had a medical condition preventing him from perspiring.
- He had investigations carried out to establish whether a photograph of him with Ms Giuffre was faked, but they were inconclusive
- He would testify under oath if "push came to shove" and his lawyers advised him to
- He was unaware of an arrest warrant against Epstein when he invited him to Princess Beatrice's 18th birthday party at Windsor Castle
- He does not regret his friendship with Epstein because of "the opportunities I was given to learn" from him about trade and business
- Speaking out about his relationship with the financier had become almost "a mental health issue" for him
Addressing Ms Giuffre's claims that she had dined with the prince, danced with him at a nightclub, and went on to have sex with him at the house of Ghislaine Maxwell, a friend of the prince, in Belgravia, central London, he said "there are a number of things that are wrong with that story".
He said the date when Ms Giuffre says he had sex with her was 10 March 2001, when he had taken his daughter Beatrice to Pizza Express in Woking for a party before spending the night at home.
"Going to Pizza Express in Woking is an unusual thing for me to do," he said. "I remember it weirdly distinctly."
Ms Giuffre described him providing her with alcohol at a nightclub, but Prince Andrew said: "I don't drink, I don't think I've ever bought a drink in Tramps whenever I was there."
On claims he was sweating, he said: "I have a peculiar medical condition which is that I don't sweat or I didn't sweat at the time," he said, blaming it on "an overdose of adrenaline in the Falklands War".
He said he had only started to be able to sweat again "in the recent past".
Asked about a photograph of him and Ms Giuffre being taken at Ghislaine Maxwell's house, he said he had "absolutely no memory" of it.
"Investigations that we've done" have been unable to prove whether the photograph was faked, he said, "because it is a photograph of a photograph of a photograph".
Prince Andrew said he did not recall going upstairs in that house, said he was not dressed as he usually would be if he was in London and added "we can't be certain as to whether or not that's my hand".
"I'm at a loss to explain this particular photograph," he said.
A thick skin
On the further accusation that he had sex with her in New York, the duke denied he was present at Epstein's home that day, although he had been travelling in the US.
He also denied the claim he had sex with her on Epstein's private island with a group of seven or eight other girls. "Absolutely no to all of it," he said.
Prince Andrew said he never suspected Epstein's criminal behaviour on his visits, describing the house as a busy place with staff like Buckingham Palace.
He said: "I live in an institution at Buckingham Palace which has members of staff walking around all the time and I don't wish to appear grand but there were a lot of people who were walking around Jeffrey Epstein's house. As far as I aware, they were staff."
But he denied that there were large numbers of underage girls present and said Epstein "may have changed his behaviour patterns not to be obvious to me".
Asked if he would testify under oath, the duke said: "I'm like everybody else and I will have to take all the legal advice that there was before I was to do that sort of thing. But if push came to shove and the legal advice was to do so, then I would be duty bound to do so."
'The wrong thing to do'
The duke rejected the perception of him as "the party prince" in the past, and said "going to Jeffrey's was not about partying, absolutely not".
He said he had first met Epstein through his girlfriend Ghislaine Maxwell in 1999 but it was a "stretch" to say they were close friends and they saw each other "a maximum of three times a year".
Prince Andrew acknowledged he had stayed on Epstein's private island, visited his home in Palm Beach, Florida, and travelled on his private plane.
He said he wanted to learn more about the "international business world and so that was another reason" for going to visit the US financier in New York, as the prince became special representative for international trade and investment.
He invited Epstein to Princess Beatrice's 18th birthday at Windsor Castle in July 2006 but said "certainly I wasn't aware" that a warrant had been issued in May for his arrest for sex crimes.
But the duke said he ceased contact with Epstein later that year, until 2010.
Epstein was convicted of soliciting and procuring a minor for prostitution in 2008. The then 55-year-old Epstein received an 18-month prison sentence after prosecutors forged a deal with him.
In July 2010, Epstein was released and in December, Prince Andrew went to visit him in his New York mansion.
Challenged on his decision to stay at the home of a convicted sex offender, he said: "I went there with the sole purpose of saying to him that because he had been convicted, it was inappropriate for us to be seen together."
He stayed several days and attended a dinner party, however. "It was a convenient place to stay," he said, but added "with a benefit of all the hindsight that one can have, it was definitely the wrong thing to do".
The duke denied an account by another guest that he had been seen receiving a foot massage from a Russian woman.
Asked about a picture of him and Epstein taken in Central Park in 2010, Prince Andrew said "somebody very cleverly took that photograph" but that they had not been able to "find any evidence" that Epstein had set it up.
'A sore in the family'
The fallout over Epstein's arrest had been "a constant sore in the family", the prince said.
Following the allegations made against him in a 2015 deposition, Prince Andrew said the wider Royal Family "couldn't be more supportive" and his immediate family "were at a loss".
The duke denied the episode had been damaging to the Queen, but said "it has to me, and it's been a constant drip in the background that people want to know".
He said he would like to be able to give "closure" on the issue but "I'm just as much in the dark as many people".
He said that choosing to talk about the allegations was "almost a mental health issue to some extent for me", adding that "it's been nagging at my mind for a great many years".
Meeting Epstein after his conviction was "the wrong decision and the wrong judgement" but the allegations from Ms Giuffre were "surprising, shocking and a distraction", he said.
But he refused to entirely disavow his relationship with Epstein, saying it had "some seriously beneficial outcomes" that were unrelated to the accusations against them both.
"Do I regret the fact that he has quite obviously conducted himself in a manner unbecoming? Yes," he said.
After interviewer Emily Maitlis challenged him, describing Epstein as a sex offender, the duke said: "Yeah, I'm sorry, I'm being polite."