Edibo Ameh Mark, chairman of Omala local government area of Kogi, where the violence took place, said around 21 people were buried early on Friday.

He said the attack was a reprisal by Fulani herders after the villagers three days ago killed six of them, including two by beheading.

Violence between farmers and pastoralists has become increasingly common in recent years as population growth leads to an expansion of the area dedicated to farming, leaving less land available for open grazing by nomads' herds of cattle.

"It's tragic, we never expected something like this," resident Elias Atabo, 54, said. "The attack lasted not more than 45 minutes."

Local resident Atabor Julius said up to 100 herdsmen attacked the village on Thursday and started to shoot sporadically, adding that 19 bodies were recovered after the incident with an additional 15 found on Friday morning.

Julius said most of the casualties were older people who could not escape the assailants.

A police spokesperson did not respond to a request for comment.

Kogi is one of Nigeria's Middle Belt states, where the majority Muslim North meets the predominantly Christian South.

Competition over land use is particularly intractable in the Middle Belt as the fault lines between farmers and herders often overlap with ethnic and religious divisions.

The Boko Haram insurgency in the northeast has worsened the problem by driving herders into the Middle Belt and further south, analysts say, while climate change and increasing aridity in the North are also contributing factors.

(Reporting by Hamza Ibrahim; Writing by Chijioke Ohuocha; Editing by Bill Berkrot)