The prominent Boston minister charged last week with soliciting a prostitute pleaded for his flock’s forgiveness from the pulpit yesterday where he also apologized to his wife.

“I ask for God’s forgiveness,” A. Livingston Foxworth, the senior pastor at Grace Church of All Nations in Dorchester, told parishioners at the end of a three-hour service yesterday. “I beg for your forgiveness.”

A contrite Foxworth told a packed congregation he loved three things: God; his wife and family, and his ministry.

Toward the end of the service, he was greeted with loud applause and sang two hymns where attendants clapped and raised their hands toward the heavens.

Following the hymns, Foxworth told parishioners he only blames himself. He noted that he’s not asking for members to condone his actions. He also said, “I’m not going anywhere,” but he wants some time for reflection and “restoration.”

Foxworth was joined by his wife, Karen, and grandchildren, as a minister led a prayer for him.

Foxworth and nine other men were arrested last week during a prostitution sting, according to authorities.

Detectives from the Boston Police Department’s Human Trafficking Unit conducted an “undercover online investigation into ­illegal sexual services being offered for a fee,” according to an incident report.

Detectives posing as a sex worker on the online classified ad website Backpage.com were contacted by Foxworth and the other men, according to authorities. Foxworth agreed to pay $150 for sex and went to an address on Pine Street for an illicit rendezvous, according to police.

Once he arrived, detectives called the number Foxworth provided and it started to ring, a police report states. He was placed under arrest, and his cellphone was taken as evidence, according to authorities.

Members of the church were told not to talk to media. Reporters in attendance were barred from recording or writing during the service.

But some church members spoke to the press anyway.

“We don’t need to know what happened — it’s between him and God,” said Laura Langford.

“I love my bishop,” said Cassie Avery-Grice.

Eileen Kenner, who said she’s been a member of the church since the 1970s, acknowledged, “It’s a hurtful situation. We’ll get through it.”

However, Kenner said she forgives Foxworth. “There will be victory after this. … We love unconditionally.”

A woman who declined to give her name said she was not a member of the church but came to hear what Foxworth would say. When asked if she forgave him, she only grimaced.