A British soldier will apologise to Prince Harry for revealing intimate conversations they shared in a new book.

James Wharton, an openly gay member of the army, wrote that the 28-year-old royal saved him from a homophobic attack from fellow comrades in his autobiography 'Out in the Army' but he now plans to reach out to the prince after coming under fire for detailing their private chats.

He told The Times newspaper: "I am sending over a courtesy note. I decided that I ought to say 'sorry' in a way, I guess."

However, the 26-year-old soldier admits he isn't "sorry" for revealing Harry's heroic intervention, adding: "I don't know. I'm not sorry."

Elsewhere in the book, James discusses private conversations with the prince including Harry revealing how he lost his virginity, asking him about being gay and using profanity.

James insists he wrote about his friendship with the prince in order to be completely honest about his time in the armed forces.

He explained: "For me, the four weeks I spent with the Prince was the highlight. I would be doing myself down if I had pretended it didn't happen."

The soldier previously revealed that Harry intervened after six fellow soldiers threatened him in a homophobic attack and warned that they would be disciplined if they didn't stop.