OUAGADOUGOU (Reuters) - Burkina Faso has notified the United Nations that it will withdraw soldiers deployed as peacekeepers in Sudan's troubled Darfur region by July next year, the foreign minister said late on Friday.

The West African nation, which has a battalion of 850 soldiers serving in the nearly 14,000 troop strong U.N.-African Union hybrid mission, has suffered a series of deadly attacks at home amid a rise in Islamist militant violence.

Burkina Faso's government said in May that it would seek to bring some troops home to help reinforce domestic security.

"We have great need of battle-hardened soldiers, men of experience, men who have been on the ground. So the troops that will come from Darfur will be precious for securing our borders," Foreign Minister Alpha Barry said.

Burkina Faso was rocked in January by an attack on a hotel and restaurant in its capital, Ouagadougou, claimed by al Qaeda in the Islamic Maghreb, that killed 30 people. It has continued to suffer sporadic attacks this year.

"From April 2015 to October 2016 we've had some 20 attacks, including two kidnappings of foreigners," Barry said. "We can't continue to have our troops abroad while we have internal needs to confront this asymmetrical war."

The Darfur mission, UNAMID, was established in 2007 to try to stem the violence in the restive region, where prosecutors for the International Criminal Court accuse Sudan's President Omar Hassan al-Bashir of committing genocide.

Barry said Ouagadougou had also requested that its troops serving in a U.N. peacekeeping mission in neighboring Mali be deployed to areas along the border with Burkina Faso.

"There is no problem in principle concerning this question," Mahamat Saleh Annadif, the head of the Malian mission, MINUSMA, said on Friday following a meeting with Burkina Faso President Roch Marc Christian Kaboré.

"Even now, this contingent is not very far and in the coming days a redeployment will take place so it is even closer."

Mali has been a haven for Islamist militants since groups, some with links to al Qaeda, seized its desert north in 2012. They were pushed back by a French military intervention in 2013 but have stepped up attacks across the region this year.

(Reporting by Mathieu Bonkoungou; Writing by Joe Bavier; Editing by Catherine Evans)