>>50186225>>50186470You'll need to buy a 2DS/3DS and one copy of any gen 5 game. You'll also need to buy a subscription to Pokemon Bank (unless you're willing to wait a year since it will become free in March 2022).
You'd need to transfer the Pokemon from your gen 4 games to a gen 5 game using the Poke Transfer feature within the gen 5 games. This involves using two DS/3DS consoles and playing some shitty mini-game where you can only transfer 6 Pokemon at a time.
Then once the Pokemon are in a gen 5 cartridge, you can download the Pokemon Bank and Poke Transporter 3DS apps. Both can be downloaded for free from the eShop, although Bank requires a subscription of $5 a year to use. You'll need to download both of these before March 2023 if you ever plan on doing transfers, since the eShop will be discontinued after that. If you have the apps already installed, Pokemon Bank will be free to use after this date though without requiring a subscription but you'll be unable to download it after this point. If you have all this, you can use the Poke Transporter app to transfer everything from Box 1 in your gen 5 game into Pokemon Bank. Then once it's in Bank, you can link it to Pokemon Home.
Alternatively, if you're willing to hack your switch you can use something like PKHeX to just clone your Pokemon on the DS games and inject them into your Switch game. I haven't played around with these, so I'm not sure if you can directly inject them into Home or whether you would need to buy LGPE/SwSh and inject them into there first (in which case you would be limited on which Pokemon you can inject).