Photosynthesis can be seen as the process of taking energy from the sun and converting it into glucose. With a few rare exceptions, that conversion of sunlight energy is the only way energy rich molecules can be synthesized. No energy conversion from the sun means that there would be no primary producers. If there are no primary producers there can be no consumers.
To put it another way, almost all food chains rely on photosynthetic organisms like plants because they produce their own energy. We as humans cannot do this. We have to consume our energy, either a plant or something that ate a plant.
Almost everything relies on photosynthesis to provide energy. The only exceptions are some species called extremophiles who can produce energy without light or photosynthesis. These are very rare.