Magnets
All my minis have magnetized bases. I glue a magnetized sticker under each base. As most of my minis are now on 25mm round bases, I can simply order the matching magnets from Amazon and glue them.
My main reason for adding magnetized bases was for storage. Doing so I can just put all my minis in a box with a steel sheet at the bottom and don’t care about them bumping into each other.
But what I also discovered is that it helped me for basecoating and for painting as well.
I add the magnetic sticker to the base as soon as I glue the mini on the base, even before basecoating. That way, I just have to put the minis in a nice row on a steel plank (I use the cover of a biscuit box in metal for that), and base coat on that. That way I can spray all over it without having the mini tumbling because of the wind. At some point I had been using Blu Tack to keep my minis in place, but magnetized bases is so much easier.
As for painting, I now have a few metal shelves on my painting desk, and I can just drop minis on it easily without them ever falling from the shelves.