Getting picture frames to stay straight usually requires a level or a good eye. Reformed villain blog Evil Mad Scientist suggests placing rubber feet on the back of your frames to keep them in place.
Packs of rubber feet stickers can be found at craft stores. By attaching some to the backs of your framed pictures, you can ensure the photo or artwork stays level. As a bonus, this creates a buffer so that you don’t risk damaging your walls with the pointed corners of the frame.
Cure that crooked picture frame with rubber feet [Evil Mad Scientist]