My vet neuters/spays at 6 months. This is before they start doing "big dog" stuff and usually will help them from forming bad habits.
One of my dear dogs that I got from a private rescue neutered him at 3 months (that was years ago) and he never had any problems (lived to be 11, eventually developed cancer behind his eye).
Louise and Zachary who is being a PIA today