I was searching everywhere for a solution to this because I was getting weird jittering on all of my animations going for Blender to UE5. Turns out UE5 needs the X axis as the primary bone axis and the Y axis as the secondary bone axis for FBX import (these are FBX export settings you can change in Blender). Animations will still import with them flipped, but it will cause the curves between baked keyframes to go wonky sometimes. I’m posting this solution in case anyone is desperately searching, lol.