Twenty-one people were injured on Sunday when a bomb exploded at São Paulo.

The parade is thought to be the largest Pride event in the world with almost three million visitors. It is now in its 13th year.

According to the Latin America Herald Tribune, the device was thrown into a crowd of people at around 9pm in a popular gay area in downtown Sao Paulo.

Four people were taken to hospital, although 17 were treated at the scene by paramedics for minor shrapnel injuries.

Parade spokesman Pedro Xavier told AP it is thought that a resident angry over the noise threw the explosive into the street from a window.

However, he added that the attack may have been anti-gay as the attacked “was prepared, because nobody has a bomb just sitting around at home.”

One of those hospitalised has head trauma, which another is said to be in a serious condition with multiple injuries. Two others have non-life threatening injuries.