Photosynthesis is the process by which plants, algae, and some bacteria use sunlight, water and carbon dioxide to produce oxygen and energy in the form of glucose. Chlorophyll, located in chloroplasts, absorbs sunlight and uses it to convert carbon dioxide and water into oxygen and energy-rich glucose. Two stages occur - the light-dependent reactions where ATP and NADPH are produced, and the light-independent reactions where carbon is incorporated into carbohydrates like glucose using the ATP and NADPH produced in the light reactions.