Malaysia's ruling Barisan Nasional (BN) coalition has won the country's 13th general election amid allegations by the Opposition of widespread fraud.

The ruling coalition faced an unprecedented challenge from the opposition Pakatan Rakyat alliance in Sunday's election, but ceded just two seats to finish with 133, a firm majority in the 222-member parliament.

The win extends BN's 56-year reign of power, making it one of the world's longest-serving governments.

Election authorities said a record 80 per cent of the multi-ethnic country's 13 million registered voters, or more than 10 million people, turned out to vote on Sunday.

Barisan's clear majority was secured with just 49 per cent of the vote, making Prime Minister Najib Razak the country's first leader to win with a minority of the popular vote.

Mr Najib has urged the opposition to accept the result.

"Despite the extent of the swing against us - not only during the 14 days of campaigning but for the last 5 years - the Opposition tried to disturb and otherthrow us, but praise to God we are still in power."

Support for the ruling coalition from ethnic Malays remained strong but ethnic Chinese voters, who make up a quarter of the population, continued to desert the ruling coalition, accelerating a trend seen in the previous election.

Ethnic Chinese are increasingly turning to the Opposition, attracted by its pledge to tackle corruption and end race-based policies favouring ethnic Malays in business, education and housing.

Following the announcement of the results, Mr Najib said the government would work towards national reconciliation.

"We will work towards more moderate and accommodative policies for the country," he said.

"We have tried our best but other factors have happened...We didn't get much support from the Chinese for our development plans."

Some voters have taken to the internet to accuse BN and the Election Commission of trying to steal the election after indelible ink that Mr Najib touted as a guarantee against voter fraud was found to wash off easily.

Videos, pictures and first-hand accounts of purportedly foreign "voters" being confronted at polling centres by angry citizens have also gone viral online.

Australia reacts

The Australian Foreign Minister, Bob Carr, has welcomed the outcome of the election and says that Canberra is prepared to work with either the opposition or Barisan Nasional.

Mr Carr says claims by the opposition leader that there was voting fraud are a matter for Malaysia's electoral commission.

"Our High Commission in Kuala Lumpur has followed the election closely but we can't determine whether there were unfair practices in Sabah or ink marks on fingers that washed off easily in Western Malaysia - it's not up to us to determine these things," he said.

But Australian Independent Senator Nick Xenophon says his contacts in Malaysia have told him there was massive cheating in the election.

Senator Xenophon has had a long interest in Malaysia and was recently expelled from the country by the authorities after being accused of interfering in the country's domestic affairs.

He says the leader of the Bersih movement for free and fair elections, Ambiga Sreenevasan, told him there has been widespread cheating.

"She said there has been massive cheating, that the indelible ink that was supposed to be the key factor to make sure that voting was going to be free of corruption, was in fact washable and not indelible," Senator Xenophon said.

Senator Xenophon says there's another issue with the media coverage leading up to the vote.

"The election campaign that was played out on national television - the opposition didn't get a second of air time a part from being vilified in the nation's media," he said.

"These elections were not free, they were not fair and there is evidence of widespread cheating,"

"I'm very disappointed with the standoffish role that our Foreign Minister Bob Carr has played on this," he said.