Today, only nine countries possess nuclear bombs. This outcome was not inevitable, as technology for building them rapidly spread all over the world, enabling countries with limited GDP to develop a bomb given sufficient dedication and resources. Since the 1940s, many countries have attempted to do so, but most ultimately chose not to pursue nuclear bomb after carefully weighing the advantages and disadvantages of military nuclear programmes.
The quotes below, taken from 'The Puzzle of Non-Proliferation' by Carl Robichaud, shows how even the US believed that by the 1970's, 15 to 25 countries could have obtained 'military nuclear capabilities':
At that time, only the U.S., the USSR, and the U.K. had nuclear weapons, but the “physical ability” to develop the bomb was spreading rapidly. Many countries were planning or building enrichment and reprocessing facilities capable of generating bomb fuel. These capabilities were accelerated by widespread nuclear trade, especially via the Atoms for Peace program, through which the U.S. shared civilian nuclear facilities as an extension of its soft power. Starting in the 1950s, a dozen countries seriously considered or pursued nuclear weapons. Early movers included Sweden, Canada, and Australia, followed by many industrialized countries in Europe and Asia.
In a March 1963 press conference, then U.S. President John F. Kennedy warned that 15 to 25 states might obtain military nuclear capabilities by the 1970s. Author and former U.S. security official Peter Lavoy, in a review of declassified documents, notes that Kennedy “based this pessimistic forecast on a secret study that Secretary of Defense Robert McNamara had given the president one month earlier. In this document, McNamara expected that by 1973 eight new states might acquire nuclear weapons — China, Sweden, India, Australia, Japan, South Africa, Germany, Israel — and that, shortly thereafter, many more countries could go nuclear as the cost of acquiring nuclear weapons ‘may come down by a factor of two to five times."
What's interesting is that Switzerland was the first country to start studying the possibility of building nuclear weapons, just 2 weeks after the bombings of Hiroshima and Nagaski. Its military nuclear programme lasted until 1988(!). Switzerland is now a signatory of the Treaty on the Non-Proliferation of Nuclear Weapons (NPT), and in 2017 it came close to signing the Treaty on the Prohibition of Nuclear Weapons (TPNW).