Last Friday's report from the United Nations confirms the huge danger from our continued dependence on fossil fuel. But one simple thing can break this dependence. It needs to be cheaper to produce non-carbon energy than it is by digging up coal, gas or oil. Once this happens, most of the coal, gas and oil will automatically be left undisturbed in the ground.

To make non-carbon energy become competitive is a major scientific challenge, not unlike the challenge of developing the atom bomb or sending a man to the moon. Science rose to those challenges because a clear goal and timetable were set and enough public money was provided for the research. These programmes had high political profile and public visibility. They attracted many of the best minds of the age.

The issue of climate change and energy is even more important and it needs the same treatment. In most countries, there is at present too little public spending on non-carbon energy research. Instead, we need a major international research effort, with a clear goal and a clear timetable.

What should it focus on? There will always be many sources of non-carbon energy – nuclear fission, hydropower, geothermal, wind, nuclear fusion (possibly) and solar. But nuclear fission and hydropower have been around for many years. Nuclear is essential but faces political obstacles and there are physical limits to hydropower. Nuclear fusion remains uncertain. And, while wind can play a big role in the UK, in many countries its application is limited. So there is no hope of completely replacing fossil fuel without a major contribution from the power of the sun.

Moreover, the sun sends energy to the Earth equal to about 5,000 times our total energy needs. It is inconceivable that we cannot collect enough of this energy for our needs, at a reasonable cost. The price of photovoltaic energy is falling at 10% a year, and in Germany a serious amount of unsubsidised, solar electricity is already being added to the grid. In California, forward contracts for solar energy are becoming competitive with other fuels and they will become more so, as technology progresses.

But time is desperately short and there are two even bigger scientific challenges. The first is to make solar power available on a 24-hour basis, when the sun shines only part of the day and can be obscured by cloud. This requires a major breakthrough in the storage of electricity.

The second is to reduce the cost of transmitting electricity from areas of high luminosity and low land value to the major population centres of the world. Better storage requires major breakthroughs in the science of batteries; better transmission requires new materials that are much better at conducting electricity without loss of power. In all these cases, the solution requires new disruptive technologies.

So here is our proposal. There should be a world sunpower programme of research, development and demonstration. The goal would be by 2025 to deliver solar electricity at scale to the grid at a cost below the cost of fossil fuel. All countries would be invited to participate. Those who did would commit, in their own countries, to major new programmes of research, internationally co-ordinated, and to share their findings for the benefit of the world.

Each country would have the goal of demonstrating bulk supply of unsubsidised solar electricity in scale to the grid by 2025. At the world level, the target would be for solar electricity to be at least 10% of total energy supply by 2025 and 25% by 2030. Countries' contributions to this target would be closely watched.

The programme would be truly broad. It would cover non-grid solar as well as grid electricity. And it would be of value to wind electricity as well, through improving storage and transmission.

Unlike fossil fuel, solar produces no pollution and no miners get killed. Unlike nuclear fission, it produces no radioactive waste. It harnesses the power of the sun, which is the ultimate source of most energy on Earth. And it can strike the imagination of a people and therefore of their politicians.

A central role of governments is to promote new public knowledge. Surely the most important knowledge of all is how to preserve human life as we know it. In 2015, the nations of the world will meet to agree their commitments on climate change. Whatever else they agree, they should go for a major sunpower programme.

Sir David King will be the foreign secretary's special representative on climate change from 1 October. Lord Layard is former founder-director of the Centre for Economic Performance at the LSE.