Paul Massey abruptly ended his campaign for mayor Wednesday. The Cushman & Wakefield executive, who ran on a platform of fiscal responsibility as a Republican, said the cost of sustaining a campaign was prohibitive.

“Unfortunately, the cost of running for office is extraordinary, and I do not see a path to raising the necessary funds to beat an incumbent mayor,” Massey said in a statement Wednesday. “I am forever indebted to my family, team and my friends for their support.”

Massey’s decision to drop out was seen by some industry insiders as a surprise.

“Everybody was shocked,” said Red Apple Group CEO John Catsimatidis, who lost to Joe Lhota in the Republican mayoral primary in 2013. Catsimatidis was in attendance at the Crain’s GOP debate at the Yale Club on Wednesday morning, where Massey squared off against Staten Island Assembly member Nicole Malliotakis.

“Why would he speak there if he was going to do this?” Catsimatidis said. His exit leaves Malliotakis as the leading GOP contender.

Massey’s fundraising ability was expected to be a key component of his campaign, as many outsiders predicted he would have little trouble raising the kinds of donations from his friends in the real estate industry to compete with Mayor Bill de Blasio.

He modeled his candidacy on that of Michael Bloomberg’s, talking up his managerial skills and ability to successfully run a large brokerage, Massey Knakal Realty Services, which he sold for a reported $100 million to Cushman & Wakefield at the end of 2014. He even pledged to forego the city’s public matching-funds program and had a strong showing for the first filing period in January, when he posted a haul of $2.9 million. A large portion of that, however, came from $1.3 million in personal loans he made to the campaign.

As of late March, the campaign was spending much more money than it was taking in, excluding the candidate’s personal loans. The most recent filings with the New York City Campaign Finance Board show Massey’s campaign with a balance of just $607,963. So far he’s spent $5.1 million, but only raised $3 million from donors. Massey’s lent the campaign a total of $2.7 million.

From the get-go, the candidate faced an uphill battle as a political-unknown with little name recognition facing an incumbent mayor. When Massey jumped into the race, De Blasio’s own future looked unsteady as he was facing multiple law enforcement investigations focusing on alleged fundraising improprieties and pay-to-play scandals. The investigations against the mayor were dropped, though, creating a clearer path to re-election.

Massey spent much of his time on the campaign trail attacking de Blasio. A large part of his media strategy was issuing statements lambasting the much-criticized mayor’s actions, on issues such as the corruption probe into de Blasio and his perpetual lateness. In the course of his campaign, he secured the endorsements of the Independence Party of New York, Rev. Michael Faulkner, and even former Florida Gov. Jeb Bush.

But Massey faced criticism for his lack of substantive policy stances on issues such as the controversial stop-and-frisk policing tactic.

In May, he tweeted that he would fight to revive the 421a program, even though it had already been revived the previous month.

The entrance of a serious Republican opponent such as Malliotakis could have been the death knell to Massey’s mayoral aspirations.

“There’s a definite rift in the Republican Party, and Malliotakis brings a lot of votes,” said political strategist Hank Sheinkopf, who pointed out it takes an exceptional candidate to unseat an incumbent mayor in New York City.

“Being a candidate is very difficult,” he added. “Massey’s a great real estate guy, but that doesn’t make you into a great political candidate.”

Hiten Samtani contributed reporting.