HALIFAX -- Voters in Nova Scotia dumped the NDP and their leader Tuesday after giving Darrell Dexter a historic election victory four years ago, turning this time to Liberal Stephen McNeil, who swept to power on promises to bring soaring electricity rates under control while putting an end to corporate handouts.

It's been 14 years since the Liberals were in government and McNeil returns the party to its glory years of the 1990s with a majority, winning 33 seats in the 51-seat legislature.

"I am so humbled and honoured that Nova Scotians have put their trust in me and our Liberal team," McNeil, 48, said at a party celebration in his hometown of Bridgetown.

"It is with a deep sense of responsibility and purpose that I will make certain that our plan is delivered and that our commitments are kept."

Dexter, 56, lost his seat in Cole Harbour-Portland Valley by 31 votes after a tight battle in the Halifax-area riding, an area he represented in the legislature for 15 years. Several of his top cabinet ministers including those who held the portfolios of Justice, Education and Energy, also went down in defeat as the NDP plummeted to third place with seven seats.

The party imploded in the Halifax area, where 19 seats were up for grabs. Only two NDP members survived the Liberal surge.

"Anyone who gets into politics has to know that it's about losses as well as wins," said Dexter, his voice strained with emotion at times.

"Nova Scotians made a historic choice four years ago when they elected the NDP. I was humbled by the challenges and the opportunities that we faced. We New Democrats had been conscientious critics, but Nova Scotians had never before put us to the test. Nova Scotians, I know that we didn't meet every expectation."

Dexter said he would meet with the party executive in the coming days to discuss his future.

"Friends, it was a tough campaign," he told party supporters at a Halifax hotel. "We will have time to reflect on the last 30 days and on the last four years, learning as we go forward."

McNeil overcame a barrage of attacks ads from the NDP who questioned whether he had what it takes to be premier with the tagline: "Stephen McNeil, Not Worth the Risk."

The former owner of an appliance repair business, who was easily re-elected in his riding of Annapolis, led the Liberals to victory after falling well short in 2009, when the party won 11 seats as the NDP swept the province.

This time around, the Liberals made big gains at the expense of the NDP, which fell from the 31 seats they won in June 2009.

Progressive Conservative Leader Jamie Baillie, who made tax cuts and frozen power rates the central commitments of his campaign, becomes leader of the Opposition with 11 elected members, up from the seven the party had when the campaign began.

"Tonight shows that when you have the right ideas, when you have the right plan, when you have the people of Nova Scotia in your heart, you cannot keep a good team down," Baillie said in Springhill after winning his riding of Cumberland South.

This was the first election as party leader for Baillie, a 47-year-old chartered accountant who was once chief of staff to former Tory premier John Hamm.

Though the Tories won four more seats than the New Democrats, the NDP had a slight edge in the popular vote.

Prime Minister Stephen Harper issued a statement congratulating McNeil.

"I look forward to meeting and working with premier-designate McNeil on issues of importance to Nova Scotians and all Canadians, including promoting jobs, growth and long-term prosperity," Harper said.

McNeil ran a safe campaign, offering no great spending initiatives in a platform that promised to chop the number of health districts, cap classroom sizes and reduce spending, except for Health and Education, by one per cent annually. Roughly at the midpoint of the 31-day campaign, McNeil made whistlestop visits to ridings in the Halifax area with Liberal Leader Justin Trudeau, the only federal leader to help his provincial counterpart during the race.

For Dexter, the defeat marked a stunning reversal of fortunes since he became the first NDP premier to govern a province in Atlantic Canada. Instead, Dexter's party had the distinction of becoming the first government in 131 years to be denied a second term in Nova Scotia.

The loss leaves Manitoba with the sole NDP government in Canada.

"We didn't see this kind of erosion, but you know in politics, you have to deal with what you have in front of you and that's what the party will do," Dexter said.

"They'll move forward."

Dexter said he was to blame if the NDP had trouble communicating its message to Nova Scotians.

When the party came to power, Dexter inherited a fragile economy and a massive deficit, which he blamed for breaking a key promise when he hiked the harmonized sales tax by two percentage points. The unpopular move was the one of several that tested the electorate's patience, including the NDP's failure to balance the budget as often as they promised during the 2009 election campaign.

His party was also stung by the departures of several key cabinet ministers who decided not to run again, particularly in Halifax, the party's traditional base of support.

Dexter sounded almost apologetic from the outset of the campaign, acknowledging when he called the election that his government had made mistakes, but he chalked them up to the lessons a party learns when it's new to power.

In debates during the campaign, he asked voters to give the party an opportunity to continue the progress it had made on improvements to emergency health care in rural areas of the province, and on jobs and the province's energy future.

The payoff from the NDP's energy and jobs strategy have yet to materialize. A plan to link the province to the Muskrat Falls hydroelectric project in Labrador is still waiting for final regulatory approval and jobs that are expected at the Irving Shipyard to build a new fleet of warships for Canada's navy are still down the road.

The NDP believes a renewable energy future for the province based on Nova Scotia Power's plan to tap into Muskrat Falls will stabilize electricity rates in the long term. The two opposition parties made power rates a central issue in their campaigns, with McNeil promising to break Nova Scotia Power's monopoly in the province by allowing others access to the province's energy grid and Baillie promising a rate freeze.

The Tories and Liberals also promised to stop giving companies government aid to create jobs and were critical of a $260-million forgivable loan to the Irving Shipyard in Halifax to help it prepare for the $25-billion federal shipbuilding program.

Voter turnout in Tuesday's election was 58.5 per cent, about a half percentage point higher than it was during the June 2009 election.