Barcelona have confirmed that they will exercise their right to re-sign Spain international Gerard Deulofeu from Everton for €12 million.
Deulofeu left Barca for Everton for €6m two summers ago, but the Catalan club included a series of clauses in the transfer which would allow them to sign him back at a later date.
One of those clauses included a buyback option on the winger worth €12m, which they had until June 30 to activate.
"Barcelona have exercised their right to re-sign the player Gerard Deulofeu," the club said in a statement on Friday. "In the coming days, the necessary conditions to complete the deal will be finalised with both Everton and the player. Deulofeu's contract with Barcelona is until 2019."
Although neither club confirmed the specifics of the original deal, former Everton coach Roberto Martinez explained some of the small print at the time.
The now-Belgium boss said that if Barca took Deulofeu back they couldn't sell him for one season and that if they then decide to sell him within 12 months, Everton would be entitled to a "big" percentage of the sale.
Deulofeu came through Barca's La Masia academy and was tipped to be a first-team star as a teenager, but he struggled to live up to those lofty expectations.
After loan spells of varying success with Everton and Sevilla, he eventually joined the former on a permanent deal in 2015 but failed to gain a regular first-team place before joining Milan on loan earlier this year.
His performances in Italy subsequently earned him a call up to Julen Lopetegui's Spain side and has now led to Barca taking the decision to bring him back to Camp Nou.
Deulofeu, who will captain Spain in the UEFA U21 Championships final against Germany on Friday, becomes the Blaugrana's second signing of the summer, following the permanent arrival of Marlon Santos earlier this month.