The shootout started when members of rival gangs encountered each other during a funk event at the popular Stuttgart Danceteria club in Porto Alegre, police said.
Ten people sustained gunshot wounds and the others suffered injuries when they fell or were hit while trying to get out of the nightclub.
One person hurt in the shootout refused to be transported to the hospital by paramedics.
A 19-year-old man taken to Pronto Socorro Hospital died around noon Monday from gunshot wounds, hospital spokesmen said.
Three men entered the club around 3:30 a.m. and opened fire on the people inside, police said.
The gunmen fled the area before police arrived, but officers arrested two other suspects who fired shots at them outside the club.
Three other individuals were arrested and charged with taking part in the shootout, but police did not provide further details on the arrests or their connection to the incident.
Stuttgart Danceteria’s owners said everyone entering the club was frisked to make sure they were not armed.
The gunmen who started the shootout, however, overpowered a bouncer before making their way inside the establishment.
The gang members who responded to the attack had apparently smuggled their weapons into the club inside a woman’s purse