The victim was walking with another man on Johnston Terrace when three men came up and verbally abused them.
One of the three then punched one man to the ground and two men then kicked him on the face.
After the attack, the three men ran off and were chased by two passers-by into Castle Terrace, where they lost sight of them. The victim was taken to Edinburgh Royal Infirmary for treatment.
Police Scotland appealed for information about the assault which happened at around 3.10am on Saturday morning.
Constable Neil McIntyre said: "This was a brutal, unprovoked and homophobic attack on an innocent member of the public and I am very keen to speak to anyone who witnessed the incident, particularly the two men who came to the victim's aid.
"We have descriptions of two of the men who carried out this vicious assault. Both are white British men in their mid-20s, with one being 5ft6 inches and the other being 6ft tall. Anyone who witnessed this assault is asked to contact Police Scotland on 101."