Joseph Duncan and Bryan Strachan struck victim Grant Oddoye with the work tool after they spotted him assaulting a female friend of theirs.
Duncan and Strachan, both from Edinburgh, had been sitting in a van on the city’s Leith Walk waiting on two female friends who were attending at a takeaway shop at around 1am on April 28 last year.
The two women then became involved in a confrontation with Oddoye after they saw him assault another man near to the takeaway.
One of the women was then punched to the face by Oddoye so hard she was knocked off her feet and left lying on the ground.
Duncan, 33, and Strachan spotted the attack on their friend and ran across the street to confront Oddoye.
A fight broke out and Duncan, who had grabbed an axe from his van, lashed out at the man with the work tool leaving him with cuts to his back.
Strachan also assaulted the other victim by striking him to the head during the incident.
Passers by also became involved in the fracas and as Duncan attempted to drive away from the scene he struck a man named Peter Bailey sending him crashing over the roof of vehicle.
Police had been alerted to the fight by CCTV operators who captured the whole incident and officers managed to catch up with Duncan after he had stopped his vehicle near to Great Junction Street.
Both men pleaded guilty to the axe attack on Mr Oddoye when they appeared at Edinburgh Sheriff Court in February and they returned to court for sentencing on Friday.
Duncan also admitted to a charge of careless driving while Strachan, 34, pleaded guilty to a second assault charge of striking the other victim causing him to fall to the ground.
On Friday solicitor Cameron Tait said his client Duncan had picked up the makeshift weapon as he believed one of the men had a knife and that grabbing the axe from the van had been “a moment of madness”.
The brief added victim Oddoye suffered “superficial injuries” as dad-of-one Duncan had purposely used the blunt end of the axe to strike him.
Katie Bell, defending Strachan, said her client “did not use the axe” during the attack on Oddoye and that he was “disgusted by his actions” that evening.
Sheriff Corke said: “Obviously this was a bad incident and it could have been a lot worse - neither of you had the right to get stuck in as you did.
“Mr Duncan took a work axe from his car and joined in the fight.
“It is a case where it could lead to custody but I feel in the circumstances there is an alternative.”
Sheriff Corke sentenced Duncan to carry out 240 hours of unpaid work in the community for the axe attack and fined him £320 and placed seven points on his driving licence.
The court was told Duncan already had six penalty points and will now be banned from driving for six months due to the totting up process.
Strachan will also have to complete 240 hours of unpaid work for his part in the assault.
Both men admitted to assaulting Grant Oddoye by repeatedly kicking him to the body, push him and strike him with an axe on the body at Leith Walk, Edinburgh, on April 28 last year.
Duncan also admitted to striking a man with his vehicle causing him to thrown over the bonnet and roof of the vehicle during the same incident.
Strachan admitted to assaulting a man and Duncan also admitted to striking a man with his vehicle causing him to be thrown over the bonnet and roof of the vehicle, both during the same incident.