I use this under my swim cap: Sync Hair Guard & Ear Guard Headband - Wear Under Swimming Caps
https://www.amazon.com/gp/product/B016434UTS/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1
It for the most part keeps the all the water out of my ears, though occasionally I have to adjust it. I tried earplugs and hated them - I find this so much more comfortable and easier to seal water out of my ears!