Islamic State jihadists have accepted a pledge of allegiance from the Nigerian-based Boko Haram extremists, according to an audio message.

The malevolent match comes as both ruthless groups are under increasing military pressure amid setbacks on the battlefield.

The Islamic State’s media arm, Al-Furqan, in a recording by spokesman Abu Mohammed al-Adnani, said Boko Haram’s pledge of allegiance has been accepted.

“We announce to you to the good news of the expansion of the caliphate to West Africa because the caliph … has accepted the allegiance of our brothers of the Sunni group for preaching and the jihad,” al-Adnani said in the message posted Thursday night.

He also sent a message to non-Muslims in areas controlled by the Islamic State, also known as ISIS, to convert to Islam or pay a special tax — a measure the fanatics have already put into practice in ISIS-held territories in Iraq and Syria.

“If you insist on being arrogant and stubborn … soon you will bite your fingers off in regret,” he added.

Boko Haram honcho Abubakar Shekau on Saturday posted a recording online that pledged allegiance to ISIS.

“We announce our allegiance to the Caliph of the Muslims … and will hear and obey in times of difficulty and prosperity, in hardship and ease, and to endure being discriminated against, and not to dispute about rule with those in power, except in case of evident infidelity regarding that which there is a proof from Allah,” said Boko Haram’s message.

Earlier this week, Nigerian President Goodluck Jonathan told the Voice of America that Boko Haram fighters were going to ISIS camps for training, the BBC reported.

ISIS seized much of northern and western Iraq last summer, gaining control of about a third of Iraq and Syria.

But the terror group is now struggling against Iraqi forces seeking to recapture Saddam Hussein’s hometown of Tikrit, while coming under fire from US-led coalition airstrikes in other parts of the country and in Syria.

Meanwhile, Boko Haram has been weakened by a multinational force that has dislodged it from towns in northeastern Nigeria.

But the group’s new Twitter account, fancier video messages and a new media arm all were considered signs that the group is aided by ISIS propagandists.

With Post wires