The attacker was quickly restrained by police Twitter

At least six people were stabbed when an ultra-Orthodox man attacked Jerusalem's annual Gay Pride Parade on Thursday.

Two people were seriously injured an another four hurt when a Haredi man attacked a group of marchers from behind in a frenzied assault on the parade, which is held every year in the city.

In pictures circulating on social media, the man is seen being restrained by police and wielding a huge blade near Keren Hayesod Street in the centre of the city.

"I saw an ultra-Orthodox youth stabbing everyone in his way," said Shai Aviyor, a witness interviewed on Israel's Channel 2 television.

"We heard people screaming, everyone ran for cover, and there were bloodied people on the ground."

It was confirmed later Thursday that the assailant was Yishai Shlissel, who attacked a gay pride rally 10 years ago and was recently released from prison.

Police kept a number of anti-LGBT protesters away from the march, many of whom carried placards and banners with offensive slogans.

Many of the protesters were from the far right organisation Lehava, which is also known for its picketing of mix-race weddings and virulent anti-Arab rhetoric.