The answer sits in Ansem's Report 11, and it's less an accident than an experiment.
Ansem's reasoning runs like this: open the door where a world's heart is stored and the wall surrounding that world breaks — visible to everyone else as a shooting star. That's also why Gummi Blocks can carry a ship between worlds. The Heartless cause those walls to fail, but locating a world's door takes time, and once a Keyblade has sealed it, the heart inside is probably out of reach for good.
From there he draws a connection: the Princesses of Heart and the Keyblade seem likely to resonate with one another. So he picks one special girl — not certain she carries the Princesses' power, but unwilling to ignore the possibility. She might lead him to the Keyblade's wielder.
Which is how Kairi ends up sent out onto the ocean between worlds, and washes ashore on Destiny Islands.