I had a similar issue, which turned out to be pretty simple: I had missed a part of my toenail when trimming it.
The part wasn't actually visible as I've drawn it here—it was in between the skin there. As the toenail grew, that part began to painfully poke into the skin, especially when wearing shoes.
The pain disappeared immediately on trimming off this ...
I am not aware of any tests you can do, other than subjectively analyzing your gait for stability, joint pressure, and pain.
But I can guide you to your options.
The 3 primary medical professionals who deal with orthotics are
Orthotics departments associated with orthotists/physiatrists (MD or DO physician with specialties in musculoskeletal conditions)
This is how I do it:
I pull the skin on the left side of the big toe down with my fingers - this exposes the leftover part of the nail.
I pull up the front bit of the leftover part of the nail with tweezers and thus release it a bit. This part of the nail is not attached to the nail bed, so this doesn't really hurt.
Using small pointed scissors, I cut only ...