Japan is ending its peacekeeping mission in troubled South Sudan after five years, prime minister Shinzo Abe has announced.
Mr Abe told reporters Japan would not renew the mission after the current rotation returns in May.
The 350-strong infrastructure team had been focused on road construction.
The team, which arrived in South Sudan in November, was the first from Japan with an expanded mandate to use force if necessary to protect civilians and UN staff. The Japanese military's use of force is limited by its post-Second World War constitution.
Mr Abe said Japan would continue to assist South Sudan in other ways such as with food assistance and humanitarian support, and will keep some personnel at the UN peacekeeping command office.
The decision to withdraw comes amid concern about the safety of Japanese troops in South Sudan.
There were hopes that South Sudan would have peace and stability after gaining its independence from neighbouring Sudan in 2011.
But the country plunged into ethnic violence in December 2013 when forces loyal to president Salva Kiir, a Dinka, started battling those loyal to Riek Machar, his former vice president, who is a Nuer.
A peace deal signed in August 2015 has not stopped the fighting, and clashes last July between forces loyal to Kiir and Machar triggered further violence.
The conflict has killed tens of thousands of people and forced 3.1 million to flee their homes. An estimated 100,000 people are experiencing famine, and another one million people are on the brink of starvation.
The Security Council decided in August to send an additional 4,000 peacekeepers after clashes the previous month killed hundreds in South Sudan's capital Juba.
South Sudan initially objected to the force and has delayed its deployment. Some progress on sending the extra troops has recently been made, however, and the deployment of an advance contingent of Rwandan forces is being finalised, according to a report by the UN secretary-general this week.