when the sun heats it sends rays. Some of these rays get trapped within the atmosphere and these rays are reflected back off the atmosphere. As these rays are trapped, the heat from them increases the temperature within the atmosphere leading to global warming