The sun provides us with many things, the foremost being light energy (which is converted to food by plants through photosynthesis) and heat energy (which maintains livable conditions on earth. Lets look at these in detail:
Chlorophyll containing plants converts sunlight energy into chemical energy through the process of photosynthesis. In this process, water and carbon dioxide are used in the presence of sunlight to generate glucose and oxygen. This process provides food to majority of life forms on earth. This process also ensures that earth's atmosphere stays aerobic and that carbon dioxide concentration stays in check. The heat energy provided by the sun keeps the earth's temperature at a range where life can be sustained. Without these two 'gifts' from sun, life on earth would have been impossible.
Hope this helps.