To loud cheers and renditions of the union anthem Solidarity Forever, grinning Opposition Leader Bill Shorten welcomed his victorious by-election candidate Ged Kearney as "the hero of Batman".

This was a big win for Labor.

A morale boosting victory heading into a federal election in the next 12 months in a seat the Greens have been threatening, and promising, to win for years.

As big a win for the ALP this was a savage loss for the Greens.

This was Alex Bhathal's sixth attempt at Batman.

Over her career she had successfully whittled away Labor's lead in Batman in previous elections from a safe seat to falling agonisingly close in 2016 when the party fell less than 2,000 votes short.

Now the margin is out to 4 per cent and Labor is winning the primary race.

For the Greens to go backwards is damaging for leader Richard Di Natale, and there will be many questions about their strategy which focused on stopping the Adani mine, and refugees.

Simply put, they were talking to people who were already Greens rather than talking to the all-important swing voters.

Sorry, this video has expired Labor claims victory in Batman by-election

Enemies of the leader will no doubt use the disastrous result to agitate for a change.

The party also had to deal with the reality of being a big party and all the factional tensions that come with it.

Ms Bhathal's campaign was dogged by internal leaks with nearly 20 branch members submitting a 101-page dossier of complaints accusing the veteran candidate of being a bully and a branch stacker.

Some called for her to be expelled.

This was the biggest problem — and something the Richard Di Natale has conceded: the internal leaking and white-anting of Ms Bhathal.

Alex Bhathal's campaign was dogged by leaks and white-anting. ( AAP: Joe Castro )

It was savage, it was angry and it was effective.

Her campaign was derailed and the Greens were caught on the back foot, consistently forced to put out spot fires rather than campaigning.

"It is absolutely clear that we have to get our own house in order if we're going to win back traditional Greens voters who were turned off by the leaking and sabotage from a few individuals with a destructive agenda,'' Senator Di Natale said in a short statement on Sunday morning.

But it is not the only reason the Greens failed to secure the 1 per cent swing it needed.

Labor's ground campaign simply out muscled the Greens.

And the air of inevitability that inner-city seats will turn Green has also been challenged, too many people in the Greens approached the election as a simply going to happen because of demographic change.

Labor worked harder and it showed.

Other factors hindering the Greens was that they traditionally do not get the big swings against Labor when the Coalition are in government, progressive voters would rather see a change in government.

What went right for Labor?

In two words: Ged Kearney.

A progressive, confident woman (in winning she became the first female Batman MP and boosted the number of women in the federal caucus to 48 per cent) in the most left-leaning seat in the country.

She is an experienced political animal with runs on the board and plenty of former Labor voters have appeared to have returned with Ms Kearney.

Sorry, this video has expired Caped Crusaders swarm the seat of Batman

A big positive for Ms Kearney was Labor voters returning to the party after the so-called 'Feeney factor'.

David Feeney, the retired MP who triggered the by-election, was a factional player who did not resonate with Batman voters.

He was easily targeted as a faceless man of the right faction and his 2016 campaign was bumbling at best and chaotic at worst.

On Saturday night, after acting as a scrutineer for his comrade, he was a relieved man, after all it was his failure to find his citizenship documents that caused this whole by-election.

Educated voters in the southern part of the electorate returned to Labor, having abandoned them under Mr Feeney. Volunteers also swamped back, buoyed by Ms Kearney and the strength of the union movement.

What does it mean?

This result does not affect Malcolm Turnbull's grip on power but it is a major boost for Mr Shorten.

A loss here would have given his internal enemies cannon fodder but instead his star candidate has delivered him breathing room.

It also shows that Labor can have different conversations with different constituencies — although at a general election the tightrope Mr Shorten has had to walk over issues like Adani will be much more difficult.

The significance of the victory shows that with the right — that is, left-leaning — candidate, Labor can hold off the Greens in the inner-city where it has been under threat for years, and will continue to be.

Ged Kearney celebrates with Labor supporters after the Batman by-election. ( ABC News: Andrew Altree-Williams )

Looking ahead to November 24, where Victorian Premier Daniel Andrews is facing the same Green threat in a handful of seats he needs to retain in order to remain in office, the Batman result will provide some hope.

And with Labor without a candidate in Brunswick (Ms Kearney had been preselected there) it will be well served to spend some time finding the best candidate it can.

The state electorates are smaller and will be a challenge for Labor, the key for them is to run on a key message of delivering results.

"They [federal Labor] have run a campaign that's all about Labor values and sending someone to Canberra who can get things done, not simply having someone there who can commentate from the sidelines,'' Mr Andrews said on Sunday morning.