WEST HOLLYWOOD, Calif. — Jussie Smollett, the singer and actor who said he was attacked by two men yelling racial and homophobic slurs, struck a defiant tone at a concert Saturday night, his first public appearance since he reported the assault last week.

“I have so many words on my heart that I want to say, but the most important thing I can say is thank you so much, and that I’m O.K.,” Smollett, a star of the Fox television show “Empire,” told the sold-out crowd at the Troubadour nightclub in West Hollywood.

Smollett said that although he was not yet fully healed, “I had to be here tonight.” He said he couldn’t let his attackers win, referring to them with an expletive.

The crowd, which included the “Empire” co-creator Lee Daniels and Representative Maxine Waters of California, roared in approval, though Smollett quickly followed by saying, “Now let’s have a good time.” He began his set with a cover of Stevie Wonder’s “Love’s in Need of Love Today.”