Democrat Hillary Clinton went on the attack against rival Bernie Sanders on Thursday in their most contentious presidential debate yet, questioning whether his ambitious proposals were viable and saying it was unfair to question her liberal credentials.

Sanders fought back repeatedly, accusing Clinton of representing the political establishment during a debate that featured sharp differences over healthcare, college tuition funding and efforts to rein in Wall Street.

The intensity of the exchanges reflected a race that has seen Clinton's once prohibitive lead shrivel against a relatively unknown underdog in the battle over who would best lead the Democratic Party in the Nov. 8 election and who could deliver on the party's liberal agenda.

Clinton said Sanders' proposal for single-payer universal healthcare coverage would jeopardize Obamacare, calling it "a great mistake," and she said his plans for free college education would be too costly to be realistic.

"I can get things done. I'm not making promises I can't keep," Clinton said.

Sanders said he would not dismantle Obamacare but would expand it, pointing to how many other countries provide universal healthcare.

"I do not accept the belief that the United States of America can't do that," Sanders said. "By moving forward, rallying the American people, I do believe we should have healthcare for all."

Sanders said his proposal for free tuition at public universities would be paid with a tax on Wall Street speculation. "The middle class bailed out Wall Street in their time of need. Now, it is Wall Street's time to help the middle class," he said.

Five days before New Hampshire holds the second of the state-by-state presidential nominating contests, polls show Sanders, a U.S. senator from neighboring Vermont, has a double-digit lead over Clinton after surprising the front-runner by finishing just barely behind her in Iowa on Monday.

The debate was the first since former Maryland Governor Martin O'Malley dropped out on Monday after a poor finish in Iowa.

Sanders accused Clinton of representing "the establishment," while saying he represented "ordinary working Americans." He also noted her Super PAC had taken contributions from Wall Street firms and that Clinton has received speaking fees from Goldman Sachs.

Clinton called that an "artful smear" and said she had never changed a view or a vote because of donations.

"Enough is enough. If you've got something to say, say it directly," Clinton told Sanders.

She also disputed the establishment label, saying it was "quite amusing" to accuse "a woman, running to be the first woman president, as the establishment."

The two battled over who best represented progressive ideals. Sanders said he would lead a "political revolution," but Clinton questioned his ability to get his proposals through a Republican-led Congress.

"A progressive is someone who makes progress," she said.

And she attacked Sanders' own credentials as a progressive, bringing up his votes against the 1993 Brady bill that mandated federal background checks on gun purchases.

"If we're going to get into labels, I don't think it was particularly progressive to vote against the Brady bill five times," she said.

Sanders repeated his earlier pledge not to attack Clinton on the controversy over her use of a private email account and a private server for government business when she was secretary of state.

"I will not politicize it," he said.

Clinton has tried to play down expectations for her performance in New Hampshire, where she came from behind for an upset victory in the 2008 campaign just days after losing badly to Barack Obama in Iowa.

The surprisingly strong performance by Sanders in Iowa is likely to prolong a race that Clinton entered as the presumptive front-runner.

In addition to previously scheduled debates in Wisconsin and Florida, the candidates added one in March in Flint, Michigan, to draw attention to the city's contaminated water crisis ahead of the Michigan primary. They also will debate in April and May.