Bilbao, Spain - Athletic Bilbao have strengthened their squad in the fight against relegation by signing Alaves winger Ibai Gomez.
Gomez left Bilbao to join Alaves in 2016 and helped the newly-promoted club finish ninth in La Liga.
This season, Gomez has been a key player again, with Alaves a surprise high-flier in fourth, above Real Madrid.
Bilbao have paid the 29-year-old's release clause, reportedly set at 3.5 million euros, and Gomez has agreed a contract until June 2022.
Bilbao are 17th in the table, two points above the relegation zone.
Gomez posted a video on Twitter on Thursday to bid farewell to Alaves. "The idea of saying goodbye made me cry," said Gomez. "But I am touched to return home."
In a statement, Bilbao wrote: "Athletic Club and Deportivo Alaves have reached an agreement for the transfer of the player Ibai Gomez.
"The player from Santutxu will sign a contract until 30th of June 2022."
Gomez will undergo a medical examination later on Thursday, before being officially presented as a Bilbao player on Friday.
He could make his debut at San Mames on Sunday, when Bilbao host third-placed Sevilla in La Liga.