He announced his departure in a statement on the official website of the Algerian Football Federation (FAF), which read: "I am proud of my record after serving out my contract with the FAF. Having lived for three years in Algeria, my family obligations and the attraction of new sporting challenges weighed heavily on my decision."
That led to calls for 61-year-old Halilhodzic to stay on, including from the country's president. Halilhodzic added: "I want to thank, first of all, his Excellency President Abdelaziz Bouteflika, whose warm words profoundly touched me.
"I also want to thank Prime Minister Abdelmalek Sellal for his encouragement and kind wishes, and the president of the FAF, Mohamed Raouraoua, with whom I have worked for three years to realise our objectives and who put at my disposal a squad with all the necessary means to achieve this difficult mission.
"I wish to pay tribute to the players and the technical, medical and administrative staff who gave me every assistance throughout this mission. The wonderful Algerian public wished me well since the day I first arrived and have remained loyal to me. I will always keep the fond memory of the extraordinary welcome they gave us on our return from the World Cup."