Went from mouse → trackpad → trackball. I tried fingerballs and thumbballs and settled on the Logitech MX Ergo (thumbball). Using the digit with the strongest muscles makes a lot of sense to me, although it helps to have bigger hands.
I wouldn't go back to a trackpad, even with the loss of gestures (I just use keyboard/trackball shortcuts instead), and I wouldn't go back to a mouse — pushing a rock repeatedly to move a pointer around the screen just feels weird to me now, and I notice wrist cramp within an hour.
Similar story with keyboards. I went Apple Magic Wireless → Ergodox EZ → Microsoft Surface Ergo (the default angle works great for me so I don't have to adjust anything and I like the single piece of hardware over the Ergodox; it's easier to move between rooms). I have the Keyboardio Atreus on order and am looking forward to comparing that. It seems like the perfect balance between size, features, hackability, and ergonomics to me.
Still discovered the hard way that I needed an ergonomic keyboard. I use a kinesis advantage, but frankly a Microsoft one will do. It just needs to be enough.
Also major factor: Switching away from a mouse. Every time I've done full time work at a computer (i.e. when I'm not studying), I got wrist pain.
Switching to a touchpad is tiring for the fingertip, since it's not designed to drag on a surface all day.
But switching to a trackball has been a fantastic choice (six or seven years ago by now - some kind of red Kensington ball). I think there's so much more choice in using a trackball than a mouse or a touchpad, since it can be operated with the fingertip or the hand, and it's trivial to operate it without bending the wrist badly.
I got the ergonomic keyboard before the trackball; but the trackball made an almost instantaneous difference, whereas the keyboard only makes a cumulative difference - nowadays I can use a straight keyboard temporarily (e.g. if I want to go somewhere and use a laptop, I can, even for weeks at a time) but I wouldn't want it fulltime.