It is the fourth suicide bombing this month in Maiduguri, which is the birthplace of the Boko Haram Islamic extremist group. Fishmonger Idi Idrisa said one teenager exploded as she approached the mosque crowded with people from the nearby Baga Road fish market, performing afternoon prayers during the holy month of Ramadan.
The second teen appeared to run away and blew up further away, killing only herself, he said. Civilian defence fighter Sama Ila Abu said he counted at least 30 corpses as he helped collect the dead. Both men said said there were many injured.
Boko Haram has kidnapped hundreds and hundreds of girls and women and the numbers of female suicide bombers has raised fears that it is using the captives in its campaign.
A military bomb disposal expert has told the AP that most bombs carried by girls and women have remote detonation devices, meaning the carrier cannot control the explosion.
Boko Haram has stepped up attacks since Nigeria's new President Muhammadu Buhari announced the military command centre is moving from the capital Abuja to Maiduguri in Borno State.
The attacks come as Nigeria and its neighbours are preparing to strengthen a multinational army that this year drove Boko Haram out of towns and villages where it had set up a so-called Islamic caliphate. But bombings and hit-and-run attacks have continued, along with cross-border raids.
On Thursday, a group of the extremists attacked two towns in neighbouring Niger, killing at least 40 people, the government said. In its first attack on Chad, suicide bombers a week ago attacked two buildings including the national police academy in N'Djamena, killing at least 33 people.