The high court has opened the way for big-money election campaigns from third-party groups such as unions, striking down a New South Wales law setting strict caps on such spending.

In a unanimous decision on Tuesday the court held the Electoral Funding Act – which halved the amount third-party groups can spend on state campaigns from $1.05m to $500,000 – infringed the implied freedom of political communication.

A group of unions led by peak body Unions NSW had argued that setting lower caps for groups who do not run candidates in elections – such as unions, business groups and charities – was designed to handicap “disfavoured voices”.

While the impugned law only governs NSW elections, such as the upcoming March election, the precedent will hinder federal, state and territory governments attempting to limit campaign spending.

The majority found it was unnecessary to decide on a separate provision preventing groups acting in concert to exceed the cap because there is now “no cap” for it to operate on, opening the way to unlimited spending until the law is rewritten.

Tuesday’s decision is the second major victory by Unions NSW and its affiliates against the NSW government, after they successfully challenged a total ban on union and corporate political donations in 2013.

Unions NSW secretary Mark Morey said they were “ecstatic” at the result. “We’ve basically run this case twice now and both times the High Court has said the legislation is trying silence [the government’s] critics and is not valid,” he told Guardian Australia.

The majority of the court held that the reduction in the spending cap was not “reasonably necessary” to achieve the purpose identified by the NSW government, to prevent the drowning out of other voices in the political process by the distorting influence of money.

The plurality (chief justice Susan Kiefel, Virginia Bell and Patrick Keane) and Justice James Edelman in a separate judgment rejected the NSW government’s submission that political parties occupy a privileged position which justifies a higher spending cap.

The plurality said the constitution “in no way implies that a candidate in the political process occupies some privileged position in the competition to sway the people’s vote”.

The judges accepted the unions’ submission that “no basis” was given by an expert panel in 2014 advising the NSW government to halve the cap for third-party campaigners, adding that the government had “not justified” the burden on implied freedom.

Edelman went furthest in criticism of the NSW government, siding with the unions that the law had an “additional, illegitimate purpose to quieten the voices of third-party campaigners in contrast with parties or candidates for election”.

He accepted the unions submission that this was done “to shut down … protected speech”.

Justice Stephen Gageler, by contrast, accepted that a “substantial variation” in the cap was justified. But Gageler agreed with the plurality that the NSW government had failed to show that $500,000 was sufficient for third-party groups to fairly participate in campaigns.

Similarly, justices Geoffrey Nettle and Michelle Gordon in separate judgments said the NSW government had failed to show that halving the cap was necessary to achieve its identified aim.

Morey said the result meant unions “can all get together and run a coordinated campaign” with one “overarching message”.

“Unions always rely on small donations from their members and the fees they pay,” he said. “If we want to compete against the likes of BHP, the Commonwealth Bank or Malcolm Turnbull we have to work together and pool or resources to participate.”

Morey said the unions’ campaign for the upcoming March election would focus on the privatisation of $60bn worth of government services.