The vicar, who was the second in the country to marry his partner, said the Church is now perceived as less ethical than wider society as it directly discriminates against gay people.

Father Andrew Foreshew-Cain has stepped down to join his husband in Manchester, after denying edicts from the Church of England to become the second gay priest to marry under the same sex marriage laws in 2014.

The Church of England does not carry out same-sex marriages and the House of Bishops issued guidance stating: “It would not be appropriate conduct for someone in holy orders to enter into a same sex marriage.”

Fr Andrew said that while his vicarage in St James, Sheriff Road, West Hampstead and St Mary’s with All Souls, Kilburn, have been “wonderfully affirming, progressive and inclusive”, he believes the Church of England institution does not adhere to the same ethical standards as the rest of society.

While he is leaving his vicarage to join his husband, who is chief operating officer of Co-Op Digital, Fr Andrew said he would not be able to get another job in the church even if he wanted to, as he is on a “list” following his same-sex marriage.

Fr Andrew told the Ham&High: “The church has in place practices and policies which are directly discriminatory against LGBTI (lesbian, gay, bisexual, trans, and/or intersex) people. That is institutional homophobia.

“The organisation directly discriminates against gay and lesbian people.

“And it does so freely with no consequences because it has argued from and obtained exemptions from equalities legislation.”

Fr Andrew believes that the Church of England is perceived as less ethical than the wider society around it.

“In wider society, how people respond to women and ethnic minorities and the LGBTI community has become a standard of judgement on the moral probity on that individual.

“To openly discriminate against women, to openly discriminate against gay people, is considered to be unethical and immoral...

“I think for a lot of people, both inside and outside the church, the institutional church is seen as quite clearly less ethical, less moral than the people outside of it.”

Fr Andrew is still strong in his personal faith and will join fellow Christians in prayer and support inclusion in a new congregation from his new Peak District house, which with a “delicious irony” is a former vicarage.

He will still work on a part-time basis for the Sheriff Centre at St James Church, which provides support for people in crisis.

He wrote to parishioners: “I do believe that one day the leaders of our Church will catch up with the quiet acceptance and goodness of the ordinary people of the Church.”

Fr Andrew plans to hold his last service on July 30 for St James and St Mary’s together.