Republican presidential candidate former Rep. Will Hurd of Texas is ending his long-shot bid for the White House and endorsing one of his rivals for the GOP nomination.

Hurd, a former CIA spy turned three-term congressman who in June launched an uphill bid for the 2024 Republican nomination announced on social media Monday that "it has become clear to me and my team that the time has come to suspend our campaign."

He becomes the second Republican presidential candidate to call it quits, following Mayor Francis Suarez of Miami, Florida, who dropped out of the race in August.

And Hurd – a vocal critic of former President Donald Trump, who's the commanding frontrunner for the GOP nomination as he makes his third straight White House run – endorsed former ambassador and former South Carolina Gov. Nikki Haley.

LATEST FUNDRAISING REPORTS COULD BE DEATH KNELL FOR SOME GOP PRESIDENTIAL LONG-SHOTS

Will Hurd works to try and qualify for the second Republican presidential debate

Former Rep. Will Hurd, a one-time CIA spy, addressed the GOP's annual Labor Day picnic, on Sept. 4, 2023, in Salem, New Hampshire. Hurd ended his White House bid on Oct. 9, 2023. (Fox News - Paul Steinhauser)

"Our nation deserves a leader who can unite us and navigate the complex challenges we face, particularly when it comes to our national security. I believe Ambassador Nikki Haley is the best person in this race to do that," Hurd wrote on X, formerly known as Twitter, and in an email to supporters.

Hurd emphasized that Haley, who served as ambassador to the United Nations during the first two years of the Trump administration, "has shown a willingness to articulate a different vision for the country than Donald Trump and has an unmatched grasp on the complexities of our foreign policy. I wholeheartedly endorse Ambassador Haley and look forward to supporting her for the remainder of this race."

HERE'S HOW MUCH FUNDRAISING HALEY HAULED IN THE PAST THREE MONTHS

Responding to Hurd's endorsement, Haley wrote in a social media posting, "America is at a crossroads and it's time to come together and make Joe Biden a one-term president. Thank you @WillHurd for your support and confidence. We have a country to save!"

Haley, thanks in part to well received performances in the first two Republican presidential debates, has been rising in the polls and is now second to Trump in some of the latest surveys in New Hampshire – which holds the first primary and second overall contest in the GOP nomination calendar – and her home state of South Carolina, which holds the first southern contest.

Nikki Haley in Milwaukee

Former South Carolina Gov. Nikki Haley spoke with Fox News Digital at the site of the first Republican presidential debate, in Milwaukee, Wisconsin, on Aug. 22, 2023. (Joseph A. Wulfsohn/Fox News Digital)

Hurd, who garnered little support in the GOP nomination surveys, failed to reach the polling and donor thresholds mandated by the Republican National Committee for candidates to make the stage at the debates. 

Hurd, who for part of his tenure in Congress was the only Black Republican in the House, decided against running for re-election in 2020.

THIS IS HOW MUCH DONALD TRUMP HAULED IN THE PAST THREE MONTHS IN FUNDRAISING

He grabbed national attention last year during a well-publicized book tour for "American Reboot: An Idealist’s Guide to Getting Big Things Done." In his book, Hurd urged his party to rethink its style of politics and offered ideas to reform America’s political system and keep the nation competitive against China and other powers. 

Former Rep. Will Hurd is interviewed by Fox News Digital at the New Hampshire Institute of Politics at Saint Anselm College, in Manchester on Aug. 3, 2023.

Former Rep. Will Hurd is interviewed by Fox News Digital at the New Hampshire Institute of Politics at Saint Anselm College, in Manchester on Aug. 3, 2023. (Fox News - Paul Steinhauser)

Hurd’s book – which is partly a memoir about growing up in Texas with a Black father and White mother and his CIA and congressional careers, and partly a prescription for his party and the country as a whole – appeared to some political pundits as a roadmap for a possible 2024 White House run.

CLICK HERE TO GET THE FOX NEWS APP

As he launched his presidential campaign, Hurd took aim at Trump, telling Fox News Digital at the time that "the GOP will continue to lose to Democrats if Donald Trump is the nominee."

And four months later, as he dropped out of the race, Hurd reiterated that "if the Republican party nominates Donald Trump or the various personalities jockeying to imitate his divisive, crass behavior, we will lose."

He emphasized that "while I appreciate all the time and energy our supporters have given, it is important to recognize the realities of the political landscape and the need to consolidate our party around one person to defeat both Donald Trump and President Biden. I urge donors, voters, and other candidates to unite around an alternative candidate to Trump."

And looking back at his presidential campaign, Hurd highlighted in his statement that "in 14 short weeks, my team and I matched the accomplishments of many of the other candidates in the race who had significantly higher name ID and cash advantage. I am honored to have had the support of the people who made this possible."

Fox News' Paige Dukeman, Mike Emanuel and James Levinson contributed to this report.

Get the latest updates from the 2024 campaign trail, exclusive interviews and more at our Fox News Digital election hub.