Taking the time, slowing down and being aware of writing immediately resets my handwriting.
Also, the smoothness of the pens affect your handwriting legibility. A fast pen like a Uni Jetstream makes my writing worse. OTOH, a slightly resistant roller, a gel pen or ideally a fountain pen brings out the best in my handwriting.
I practiced print and cursive letters, then my more eligible letter pairings and words in a more deliberate fashion.
I used this book, no affiliation other than I liked it: https://handwritingsuccess.com/write-now/
Inspired by this Slate article: https://slate.com/human-interest/2009/09/why-your-kids-have-...
https://sites.google.com/view/briem/free-books/handwriting-r...
I think the secret key is rhythm.
I find if I conscientiously try and write slower, it markedly improves.
It took a while, but I believe he was right - as the fountain pen forced me to write slower and more deliberately, it did improve my handwriting.
(I still (35 years later) mostly write with a fountain pen, always carrying my grandfather's Souverän 400 in my shirt pocket - it was gifted to me once I had learned to write properly.)
A math-heavy job did wonders for my handwriting.