Frequently, I need to mount a servo motor in some project--and it always seems to be a little problem, so I decided to make a "standard" (standard for me) mounting bracket using Fusion 360 (design files included so that the bracket can grow and be modified for future uses). Slide the motor into the bracket and secure it with 2-56 machine screws and nuts. Two holes are included to fasten the bracket to whatever it needs to be fastened to.
Print the bracket with a 3d printer. No supports are necessary and I used 20% fill for a little extra strength.
I included the Fusion 360 file so that the bracket could be easily modified to attach to whatever situation may be encountered. Shown in this picture is a robot arm from "Poppy," the open source bi-ped robot project.
Everything needed to build a humanoid robot can be found in the "Poppy" project.
Blinky, the Companion Robot (under construction--coming to instructables in the future) will soon wave its arm when it "sees" you. I came across the "Poppy" project and printed out their arm--just out of curiousity. Then I wanted to somehow use the arm on Blinky to make him wave "hello." This required mounting the servo motor, thus the design of the servo bracket (which morphed into a more specific bracket for Blinky).