So almost all of energy used by humans today comes (or came) from the sun, directly (solar panels) or indirectly (fossil fuels, plants, meat).
You can divide the amount of calories a human needs per day and the amount of energy is provided to earth by the sun per day and that can be the theoretical limit on how many people can live on earth if we are 100% efficient with the energy.
You can divide the amount of calories a human needs per day and the amount of energy is provided to earth by the sun per day and that can be the theoretical limit on how many people can live on earth if we are 100% efficient with the energy.