Australia’s High Court has disqualified the deputy prime minister Barnaby Joyce from sitting in Parliament in a ruling that could cost the government its slender majority.

The decision on Friday to disqualify the deputy PM over a constitutional ban on dual citizens sitting in Parliament means a by-election will be held in December.

Mr Joyce will be able to stand for re-election, having renounced the New Zealand citizenship he unknowingly inherited from his father.

Prime Minister Malcolm Turnbull’s conservative coalition has a single-seat majority in the 150-seat House of Representatives where parties form governments.

And with the government trailing the opposition Labour Party in opinion polls, voters could use the by-election to toss both Joyce and his government out of office.

Speaking to reporters after the court ruling, Mr Joyce said: “I was always apprehensive, some people say I’m a natural pessimist, I’m naturally cautious and I was always prepared for this outcome.

“I’m going to make sure that I don’t cry in my beer, I’m going to get back to work and work hard for the people of my electorate.”

The court also disqualified four of the six senators referred to court, including government minister Fiona Nash.

Senator Fiona NashSenator Fiona Nash was also disqualified (Rob Griffith/AP)

Disqualified senators are replaced by members of their own parties without an election so the balance of power is not altered.

Another government minister Matt Canavan, who the court heard might have inherited Italian citizenship from his Australian-born mother through his Italian grandparents, was allowed to stay in Parliament.

Nick Xenophon was also allowed to stay in Parliament. He was born to Cypriot and Greek-born parents and checked with both embassies to ensure he wasn’t a citizen of those countries.

He later discovered he was British because his father left Cyprus while it was a British colony.

The constitution bans dual nationals from Parliament, a prohibition that critics have condemned as outdated in a country where almost half the people are immigrants or have an overseas-born parent.

The lawmakers were exposed as dual citizens as media scrutiny escalated after Scott Ludlam declared in July that he was a New Zealander and had been illegally elected three times over a decade.

Previously only two politicians had ever been caught out by the foreign citizen ban, although other dual citizens have almost certainly served in the Parliament undetected.

The government had argued that only Ludlam and Malcolm Roberts, a senator in the minor One Nation party, should be expelled because they had failed to take reasonable steps to ensure that they only held Australian citizenship.

Solicitor-General Stephen Donaghue had told the High Court judges that the other five should not be disqualified from Parliament for breaching the constitution because they did not voluntarily acquire or retain citizenship of another country.

A clause in the constitution says “a subject or citizen of a foreign power” is not eligible to be elected to Parliament.

Donaghue, however, argued that the clause “cannot be read literally”.

“If a person is not aware either that they are a dual citizen or of a significant prospect that they are, in our submission by definition that person cannot have a split allegiance,” he told the court.