Nigeria's chief of defence staff, Alex Badeh, announced the truce. Boko Haram has not made a public statement.
The group has been fighting an insurgency since 2009, with some 2,000 civilians reportedly killed this year.
Boko Haram sparked global outrage six months ago by abducting more than 200 schoolgirls.
The girls were seized in the north-eastern town of Chibok in Borno state, and their continued captivity has led to criticism of the Nigerian government's efforts to secure their release.
Members of the Bring Back Our Girls campaign said in a tweet on Friday: "We are monitoring the news with huge expectations."'Cautiously optimistic'
Air Chief Marshal Badeh revealed the truce at the close of a three-day security meeting between Nigeria and Cameroon. He said Nigerian soldiers would comply with the agreement.