It can be somewhat preventable if the Gynecomastia is due to certain medical conditions or drug allergies. Professional testing is mandatory to track and prevent the causes effectively. In addition to these things, a proper intake of a balanced diet, cutting down on junk food items, avoiding the use of Tabacco & steroids, reducing alcohol consumption, regular exercising and maintaining an appropriate diet regimen is necessary.
Gynecomastia resulting due to hormonal imbalance is not preventable. There is no medical procedure that can predict future risks to hormonal imbalances and thus can occur at any time during the growth or ageing of a male.