The raid on the village of Doron Baga and its surrounding villages took place Monday, though news of the attack only emerged Friday due to poor communications.
The gunmen also injured 25 villagers and burned several homes.
"They left no men or boys in the place; only young children, girls and women," witness Halima Adamu told Voice of America. "They were shouting 'Allah Akbar' [God is greatest], shooting sporadically. There was confusion everywhere. They started parking our men and boys into their vehicles, threatening to shoot whoever disobey them. Everybody was scared."
Boko Haram translates to "Western education is sin." The group claimed responsibility for kidnapping 200 schoolgirls from the village of Chibok in Nigeria four months ago. Those girls are still missing.