The 23-year-old were also linked with Manchester City, Charlton and Everton.
A statement on Sevilla’s website said: “Kepa will play for the rest of the season at West Ham.
“The agreement between the two clubs includes an option to buy, which must be exercised before 30 June – when Kepa’s transfer to West Ham ends.”