A witness filmed the horrifying scenes as the attacker tried to thrust his knife towards police on Bourke Street.
It is unclear who the brave individual is but he managed to create enough distance between him and the attacker to provide some safety in the nail-biting moment.
An attacker went on a stabbing rampage in the city centre killing at least one person and leaving another two injured.
Video filmed from inside a nearby building shows the attacker going after two officers police officers in high-visibility clothing and trying to stab them.
Many on Twitter were quick to prasise who unknown hero with the trolley.
@Cameron_John tweeted: “I feel safe in my city knowing that somewhere out there – Trolley Man is watching over us.
@mickh05 added:”Trolley Man is my hero! #TrolleyMan #Melbourne #BourkeSt.”
Police raced to the scene after a pick-up truck car became engulfed in flames at 4:39pm local time.
Witnesses say they saw the man drive a truck into the Target centre and as the car caught fire he tried to fight and stab police and bystanders.
Police shot the man in the chest and he is now in critical condition in hospital.
Video posted on Twitter and broadcasted on television showed an officer raise his weapon and then a shot is heard before the attacker falls to the ground clutching his chest.
One witnessed tweeted from the scene.
Melbourne resident Meegan May tweeted: “Chaos in Bourkest as a guy seems to have set his car on fire then attacking police with a knife.
“Police response was swift and overwhelming.
“I heard at least one gun shot initially”.
The witness can be heard screaming as the knifeman gets his weapon just inches from the officer’s face.
Three people have been stabbed, including the fatality.
The other two are into the hospital including one suffering from a neck injury and is suspected to be in critical condition.
Police said there was no terrorism link at this stage but they are “keeping an open mind”.
Speaking at the scene, Superintendent David Clayton said: “Police quickly responded to the incident.
“As they got out of the car they were quickly confronted by a male brandishing a knife and threatening them.
“At the same time passers-by were pointing out that members of the public had been stabbed.
“Police shot the male and he is now in a critical condition and under guard in hospital.
“Three people have been stabbed. Unfortunately one is dead at the scene, two others are at hospital.”
The street where the car caught fire is the same one when in January 2017 a fatal but not terror-related incident when a man plowed his car in to pedestrians at a high speed, killing six people and woulding about 30.