When a group of people called the Yayoi came into the Ryukyu Islands, they brought over a language called Proto-Japonic. This language over time turned into the modern Ryukyuan languages. Proto-Japonic was also spoken in mainland Japan, which turned into Japanese, meaning Japanese and the Ryukyuan languages are related/have the same origin.