Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

David Clarke, the controversial sheriff of Milwaukee County, Wisconsin, and a favorite of President Donald Trump, abruptly resigned on Thursday.

Clarke gave no reason for his resignation in a one-paragraph letter to the county clerk that was obtained by NBC News. In a statement late Thursday afternoon, he said: "After almost forty years serving the great people of Milwaukee County, I have chosen to retire to pursue other opportunities. I will have news about my next steps in the very near future."

Milwaukee County Sheriff David Clarke at the National Rifle Association's annual meeting in Atlanta in April. Scott Olson / Getty Images file

Clarke, one of most prominent African-American figures in law enforcement, is a frequent commentator on Fox News who was a strong supporter of Trump's presidential campaign. As recently as this week, the president tweeted an endorsement of Clarke's latest book, calling him "a great guy."

A great book by a great guy, highly recommended! https://t.co/3jbDDN8YmJ — Donald J. Trump (@realDonaldTrump) August 27, 2017

In a July 2016 interview on CNN, Clarke called the Black Lives Matter movement "purveyors of hate" and said it was responsible for violence against police. Clarke also aggressively pushed his department to partner with the Department of Homeland Security to crack down on and round up undocumented immigrants.

The Morning Rundown Get a head start on the morning's top stories. This site is protected by recaptcha

Christine Neumann-Ortiz, executive director of Voces de la Frontera, a nonprofit Wisconsin activist group that strongly protested the arrangement, called Clarke's resignation "wonderful news."

"This is a tremendous victory for the community, for the people of Milwaukee County [and] for the state," she said Thursday.

In a separate written statement, Voces called on Wisconsin Gov. Scott Walker, who will appoint an acting sheriff to serve until next year's elections, to pick someone who "will stop honoring unconstitutional ICE detainer requests."

"We urge the Governor to appoint a Sheriff who will respect the dignity and constitutional rights of all residents regardless of race or immigration status, who will build accountability and trust with law enforcement, and provide alternatives to mass incarceration with the goal of creating healthy and safe communities," it said.

Milwaukee County Sheriff David Clarke speaks at the Conservative Political Action Conference in National Harbor, Maryland , in February. Chip Somodevilla / Getty Images fil

County Executive Chris Abele, a critic who called on Clarke to resign in June, said he was blindsided by the announcement, which he learned about when his phone began ringing with calls from reporters seeking comment.

Abele said he was "excited" by the development, telling reporters: "If there's anything America doesn't need right now, it's someone who isn't going to tell you who to be angry at and who to distrust."

"We've got the opportunity to make some big steps forward," he said.

In May, Clarke said he had been offered a top spot at Homeland Security — a statement that the department declined to confirm after an inquest recommended criminal charges against seven county jail staffers in the dehydration death of an inmate who went without water for seven days.

In June, DHS said Clarke wasn't a candidate. Clarke said in response that he'd withdrawn his name from consideration.

Mark Belling, a conservative Milwaukee radio host, reported that Clarke told him that he wouldn't be taking another government position. Belling offered no other details.