Watch Hillary Clinton and Bernie Sanders in Florida on Wednesday night at 9 p.m. ET, in a debate that will be simulcast on CNN and sponsored by The Washington Post and Univision.

Washington CNN  — 

Bernie Sanders won the Michigan Democratic primary, CNN projects, in an upset that delivers a sharp blow to Hillary Clinton’s hopes of quickly securing her party’s nomination.

Sanders’ victory, on the eve of the next Democratic debate clash that will be simulcast on CNN, raises fresh questions about the former secretary of state’s appeal to blue-collar Democrats who have embraced the Vermont’s senator’s populist anti-Wall Street message.

What went wrong for Hillary Clinton?

Although Sanders did little to cut into Clinton’s overall lead of about 200 delegates, thanks to her win Tuesday in Mississippi, his performance in Michigan suggests Sanders could mount a stronger-than-expected challenge in looming primaries in a string of Rust Belt states, including Ohio, Illinois and Wisconsin.

On the Republican side, Donald Trump won the Hawaii caucuses, CNN projected. He also won Republican primaries in Michigan and Mississippi, important victories that propel him closer to the nomination despite a week of fearsome barrage of attacks from his rivals and the Republican establishment.

Sen. Ted Cruz won the Idaho Republican primary, according to a CNN projection.

But the big surprise of the night was in the Democratic race.

5 takeaways from Tuesday’s primaries

While the Michigan defeat won’t dent Clinton’s overall advantage in the delegate race, it’s an embarrassing speed bump in her efforts to pull away from Sanders and turn her fire exclusively on the Republicans. She will now look to big state contests next Tuesday in Ohio, Florida, North Carolina and Illinois to restore her momentum.

Sanders acknowledged that the Michigan vote was close, but thanked voters for “repudiating” polls that indicated Clinton had stronger support in the state.

“What tonight means is that the Bernie Sanders campaign, the people’s revolution that we’re talking about, the political revolution that we’re talking about, is strong in every part of the country,” Sanders said. “And, frankly, we believe our strongest areas are yet to happen.”

Even the Sanders camp appeared to be surprised by the victory, as the candidate held a rally for supporters in Florida hours before his victory was confirmed.

“We didn’t know at the end whether we were going to get over the hump or not,” Sanders campaign manager Jeff Weaver told CNN. He predicted that with most Southern states now out of the way, the calendar was turning in favor of the senator.

The Clinton campaign put a brave face on the defeat, by about two percent of the vote, after earlier warning that the race was much closer than polls that gave Clinton a big lead suggested.

Clinton communications director Jennifer Palmieri said their strategy “is built around accruing delegates and we will come out on top on delegates.”

Even though she lost Michigan to Sanders, Clinton actually won more delegates on the night, according to a CNN estimate, picking up 84 to Sanders’ 67. She now has 1,234 of the 2,383 delegates needed to win the nomination. That figure includes super delegates, party officials and officeholders who have said they will back her.

Sanders has 567 delegates overall.

Clinton team shaken by close race

The former first lady and her rival have clashed repeatedly in recent days over issues that are vital to Michigan voters. Clinton hammered her rival over a vote against a bailout for the U.S. auto industry in 2009, while the senator lambasted her over her past support for free-trade deals that he said sowed ruin in the Midwest.

“What these trade agreements have done is decimate community after community in the Midwest and all over America,” Sanders said in the state on Monday. “I have helped lead the opposition to every one of these disastrous trade agreements,” he said, “because I knew what they would do.”

Clinton’s team was shaken by the close Michigan race, sources told CNN’s Jeff Zeleny. Michigan Democrats who are aligned with Clinton’s campaign do not believe that Clinton’s attack on Sanders’ position on the auto bailout worked as they intended.

There is second guessing among some Democrats that some people in Clinton’s organization started looking beyond the primary to a general election contest against Trump.

“They didn’t take Sanders for granted as much as voters,” said one top Democrat close to the campaign.

Clinton told supporters on Monday that “the sooner I could become your nominee, the more I could begin to turn my attention to the Republicans.”

For the latest news and political buzz get the CNN Politics Nightcap | Sign up

Attacks leave Trump undiminished

Trump’s strong performance – he has now won 14 states – suggests that his capacity to win is undiminished despite a barrage of attacks by his rivals and the Republican establishment on his personality, his sometimes vulgar campaign style and his fitness to serve as president.

In a news conference Tuesday night, Trump said the results were a repudiation of “so many horrible, horrible things” said about him over the last week, which he said added up to “$38 million worth of horrible lies.”

He added: “It shows you how brilliant the public is because they knew they were lies.”

With 97% of the Michigan vote in at 1 a.m. ET, Trump was in the lead at 36.5%. Cruz was in second place at 24.9% and Ohio Gov. John Kasich was at 24.3%.

With 95% of the Mississippi vote in, Trump was in first at 47.3% followed by Cruz at 36.3% and Kasich at 8.8%.

The Michigan results could provide a lift to Kasich if he has a second-place finish, or is a close third. That performance is a good omen for his must-win primary next week in his home state of Ohio.

Still, Kasich’s only hope of becoming the GOP nominee appears to rest on corralling establishment support if Marco Rubio exits the race and hoping that a convention fight could deprive Trump of the nomination.

The results mark another miserable night for Rubio. The Florida senator was in fourth place in both of the big races. Such a poor showing will add to impressions that the campaign of a man seen as a rising star of the Republican Party is fading fast.

CNN’s Dan Merica contributed to this story