(CNN) Spain's head coach Luis Enrique resigned from his post, the Spanish Football Federation (RFEF) announced on Wednesday.
"Luis Enrique has informed us that he will not continue as manager," the Spanish Football Federation president Luis Rubiales said. "I have to thank you. We don't have the slightest reproach. We've been united with him. He will always have the RFEF doors open."
Enrique has not been part of the Spain camp since March after missing the victory over Malta because of what the national football association called "serious family problems."
Enrique's assistant, Robert Moreno, took charge of the recent European Championship qualifying victories of Faroe Islands and Sweden. The 41-year-old Moreno has been named as Enrique's successor.
In a statement, Enrique said: "Due to the fact that the reasons that stopped me from normally performing my functions as national team coach since last March are still ongoing today, I have decided to leave the post.
"All of my appreciation to the executives at the RFEF for the confidence and understanding they've shown me.
"I want to thank in particular all of those people who form part of the staff and the players for their professionalism. Without forgetting the press for its discretion and respect for the situation."
Enrique, 49, was appointed as national team coach in July 2018 after the team's catastrophic World Cup.
He signed a two-year deal and replaced interim boss Fernando Hierro who took the job after Julen Lopetegui was sacked two days before the team's first game in Russia.
Enrique, who played for both Real Madrid and Barcelona, also enjoyed huge success as head coach at Camp Nou winning the La Liga title, domestic cup and Champions League in 2015.