Nuclear weapons prevented the Cold War going hot. That alone outweighs almost any harms they have caused.
A hot war in the 40s getting rid of Stalin might have been less harmful than his actual regime. Many millions died or lived miserable lives under the soviet nuclear umbrella.
Nuclear weapons accelerated distrust, the iron curtain, and a resulting arms race. I think it was more divisive than pro-peace. But it's impossible to evaluate the counterfactual.