Since she first performed on television in October, Mayam Mahmoud's new fans have been posting up to 50 supportive messages a day on Facebook. But there have also been a few unwelcome messages. "Some say I'm creating a bad name for Islam," she says. "Or even that I'm an infidel."

A hijab-wearing rapper, Mahmoud has challenged some Egyptians' expectations of how women – and hijab wearers in particular – are meant to behave. Mahmoud, 18, is not Egypt's first veiled rapper, or even its most experienced. But through her appearances on Arabs Got Talent, a variety show that has become a primetime success across the Middle East, she is one of the few to attract something approaching mainstream attention.

"It's got a lot of people talking about whether it's possible for a veiled girl, or even a girl, to do this," says Mahmoud, who says her veil is a personal choice and has little relevance to her music. "If a girl has a dream to work in a field where many girls don't work, or to do post-graduate study, or to work in a position higher than her husband – all these things often can't be done."

Rapping is a case in point, she says. It is by no means a conventional path for Egyptian men, but for women it is twice the battle. "The girls in this field are thought to have bad morals. It's known that when a girl tries to record a track, she will just be one girl in the studio with a lot of guys for a long time. So it's hard to find someone to work with her, to create a beat, to master the track."

Mahmoud, an economics undergraduate from Cairo, says she tries not to listen to listen to western hip-hop. Her biggest influence is her mother, who introduced her to poetry aged 12 and encouraged her to write her own work. When her poetry turned into rap, her parents were initially sceptical because they felt it was not a sufficiently feminine activity for her. But gradually they grew convinced, and eventually they allowed her to record a track in Alexandria, Egypt's second city, while they waited in a cafe around the corner.

Her appearances on television constituted her first public performances. Interest in her music grew quickly, and she has since played five concerts to enthusiastic university audiences who say they find her empowering. "The other day a woman came up to me and said she'd been watching me on TV with her friends," Mahmoud recalls. "She said: keep on talking about all the things that we don't have the courage to talk about. You've become the hope. You are pushing people to start doing stuff."

Mahmoud's fans find her inspiring not just because she is a woman but because her work centres on sexual harassment, a local taboo. Harassment is an endemic problem in Egypt: 99.3% of Egyptian women reported being sexually harassed, with 91% saying they felt insecure in the street as a result, according to a UN survey published in April.

For her part, Mahmoud carries a sharp nail to protect herself in a worst-case scenario. But many women feel afraid to discuss the issue publicly because they fear they will be stigmatised. Women who speak out are often assumed to have somehow provoked the attention. "It's happening to everyone," says Mahmoud. "But everyone is scared to talk about it."

Her songs tackle harassment and victim-blaming head-on – condemning Egyptian society for accepting harassment as part of everyday life, and for laying the blame for it on women rather than men.

"I won't be the shamed one," she says in one of her raps. "You flirt, you harass and you see nothing wrong with it. But even if it's just words, these are not flirts, these are stones."

Mahmoud thinks the problem can only be tackled if women call out harassers in the street, and she hopes her rapping will encourage others to follow her lead.

"A woman will often choose to stay silent in case she's told it's her fault," said Mahmoud. "But every time we don't say anything, we make the problem bigger. Maybe the reason harassment is worse here than many other places is because we choose to shut up – and then they think they can do it more and more."

Additional reporting by Manu Abdo