The pledge to safeguard students from attack came days after a coalition that backs the government was blacklisted by the UN for airstrikes on schools.
Hundreds of its schools have been damaged or destroyed by attacks in its ongoing conflict. Millions of its children are out of school because of strike action by teachers who haven't been paid for months.
In the midst of this chaos - almost unnoticed - Yemen has become the 70th country to sign the Safe Schools Declaration.
That means the Yemeni government of President Abdrabbuh Mansour Hadi has made a public commitment to safeguard education from the effects of armed conflict.
The move came just days after the United Nations put the Saudi-led coalition - which backs the president - on a blacklist of child rights violators for carrying out 38 attacks on Yemeni schools and hospitals in 2016 that killed and maimed 683 children.
Countries that sign the Safe Schools Declaration are expressing support for protecting students, teachers, schools and universities from attack and taking measures to stop the military use of education facilities.
They also commit to collect data on attacks and misuse of schools and universities, and to investigate any attacks or other violations.
Yemen's permanent envoy to the UN, Khalid Hussein Al-Yamani, said:" By endorsing this declaration, the Yemeni government was sending a clear message to the international community that it is very keen to protect schools and children from armed conflicts".
Norway - which along with Argentina led talks in 2015 that resulted in the Safe Schools Declaration - congratulated Yemen on signing and called on more countries to do likewise.
Major countries which have not signed include the United States, United Kingdom, China and Russia - all members of the UN Security Council, which held a meeting about attacks on education recently.
Earlier this month, Yemen - which is three years into a war between the government and the Iran-backed Huthi rebel alliance - featured heavily in the UN Secretary-General’s annual report on children and armed conflict.
It said there had been 1340 child casualties in Yemen. There were 33 documented attacks on schools in 2016, with 28 air strikes by the Saudi-led coalition resulting in destruction, and 12 military uses of schools.
Six were attributed to the Houthis, four to the Popular Resistance and one each to the Yemeni Armed Forces and Ansar al-Sharia.
Classrooms in Yemen's capital Sanaa and rebel-held areas are mostly lying empty because of a strike by teachers who haven't been paid. Almost three-quarters of them have had no salary for a year.
UNICEF estimates 13,146 schools, or 78% of all of Yemen's schools, have been hit by the salary problem. Spokesman Rajat Madhok said: "The future of 4.5 million students hangs in the balance."