MILWAUKEE -- Republican Donald Trump emerged from the Wisconsin primaries as a damaged front-runner following a crushing primary loss to rival Ted Cruz, deepening questions about the billionaire businessman's presidential qualifications and pushing the Republican Party toward a rare contested convention nomination fight.

Democrat Bernie Sanders also scored a sweeping victory Tuesday giving him fresh incentive to keep challenging Hillary Clinton. But Sanders still lags behind Clinton in the all-important delegate count.

Both parties now turn their sights toward New York, which offers a massive delegate prize in its April 19 contests. It marks a homecoming of sorts for several candidates, with Trump, Clinton and Sanders all boasting roots in the state.

In the Republican primary system, candidates vie in each state to win delegates, who then vote for the nominee at party conventions over the summer. If no candidate wins an outright majority in the first vote of the convention, most delegates are free to change their allegiance, so candidates would have to compete to win their support.

Cruz has stepped forward as the candidate best positioned to block Trump in the Republican race, though it would likely take a convention battle to accomplish that goal.

A Texas senator with a complicated relationship with Republican leaders, Cruz cast his Wisconsin victory as a "turning point" in the race and urged the party to rally around his candidacy.

Even if Cruz's gains do force the Republican race into a contested convention in July, it is unclear whether he would emerge as the nominee, or whether the party would try to put forward someone else.

In the Republican race, Cruz was poised to collect most of Wisconsin's 42 Republican delegates.

In the Democratic race, Sanders still trails Clinton in the pledged delegate count and has so far been unable to persuade superdelegates-- the party officials who can back any candidate -- to drop their allegiance to the former secretary of state and back his campaign.

At a raucous rally in Wyoming, Sanders cast his victory as a sign of mounting momentum for his campaign.

"With our victory tonight in Wisconsin, we have now won 7 out of 8 of the last caucuses and primaries," he declared. Sanders is favoured to win Wyoming's Democratic caucuses on Saturday, but it offers a small delegate prize.

Because Democrats award delegates proportionally, Sanders' victory in Wisconsin did not cut significantly into Clinton's lead in the pledged delegate count.

Sanders' win will net him at least 47 delegates and Clinton will gain at least 36.

That means Sanders must still win an unlikely 67 per cent of the remaining delegates and uncommitted superdelegates in order to win the Democratic presidential nomination. The state-by-state nominating contests are choosing delegates who will select the presidential nominees at the parties' national conventions in July.

Associated Press writers Scott Bauer in Milwaukee and Julie Pace, Hope Yen, Stphen Ohlemacher and Emily Swanson in Washington contributed to this report