Daniel James is set to become Manchester United’s first signing of the summer after Swansea accepted a fee that could rise to around £18m for the Wales international. The 21-year-old is undergoing a medical at United on Thursday, after Wales gave him permission to leave their training camp, with the winger poised to sign a long-term contract.

United’s interest in James first surfaced towards the end of the season but the move was put on hold after the player’s father, Kevan, died suddenly. With James back in the international fold this week – after telling Ryan Giggs, the Wales manager, that he felt up to joining the squad – the wheels were set in motion for his transfer to go through.

Transfer window 2019 – every summer deal from Europe's top five leagues Read more

It is understood that United will pay £15m up front for James, who had 12 months remaining on his Swansea contract, with the rest to follow in add‑ons. He will be Ole Gunnar Solskjær’s first signing, with the United manager looking to rebuild after a hugely disappointing end to the campaign.

It has been a whirlwind 12 months for James, who joined Swansea from Hull City in 2014, when he was an academy player. He burst on to the scene under Graham Potter last season and quickly caught the eye with his extraordinary pace. James was set to join Leeds on deadline day in January, in a loan that would become permanent if the Championship club won promotion, but Swansea pulled the plug at the last minute.

James was bitterly upset but he never dwelled on that disappointment and turned in some outstanding performances in the second half of the season, including scoring a remarkable individual goal during the 4-1 victory against Brentford in the FA Cup fifth round, when he covered 84 yards in 8.48 seconds.

A month later James marked his first competitive start for Wales with the only goal of the game against Slovakia and by that time it was clear that he was not going to be staying at Swansea beyond the end of the season. His breathtaking speed wreaked havoc in the Championship, no more so than when Swansea beat Stoke 3-1 in April. Two Stoke players were sent off for fouling James, who also scored with a brilliant curling shot.

Swansea are continuing their search for a manager, with a second round of interviews due to finish on Friday as the club look to appoint Potter’s successor by the start of next week. Michael Appleton, the former Blackburn, Portsmouth and Oxford manager, John Eustace, who is the QPR assistant manager, Steve Cooper, the England Under-17 coach, Cameron Toshack, Swansea’s Under-23 coach, and Gus Poyet, who is out of work, are among those shortlisted.