Sometimes people think that because the primary energy is free, use of renewable energy sources should naturally grow to fill most or all of the energy needs of the world. However, energy from renewable sources currently constitutes a relatively small fraction of total energy use in the United States and worldwide. As one illustration, consider the electric power generation in the U.S by primary energy source in this figure from several years ago. Excluding hydroelectric, only about 3% of the U.S. electric power came from renewable energy. While progress is being made, and other perspectives would give somewhat different results, the main point is that renewable sources currently contribute very little to the overall energy needs of the world.
Why is this so? Part of the answer lies with the relatively high capital costs associated with renewable primary energy sources.
While renewable energy sources such as wind and solar eliminate fuel costs, they have a low energy density relative to hydrocarbon fuels. Consequently, collection, transformation, and transport costs tend to be much higher per unit of energy than for traditional fuels, and the overall (capital, maintenance, fuel) cost of providing the renewable-sourced energy is often not economical. While progress in efficiency and infrastructure continues to bring costs down, there is still a long way to go before renewable technologies replace hydrocarbon fuels on a large scale.
As an illustration, this figure shows consumer prices for small photovoltaic panels as a function of size. A rough estimate from this admittedly unscientific survey (I just looked up prices for solar panels on the internet) indicates that PV panels can be purchased for around $7000/kW.
Now, the next figure shows an estimate for payback period as a function of capital cost, interest rate, and selling price of electricity with the assumption of no fuel cost and neglecting maintenance cost. For a remotely reasonable payback period in the neighborhood of five years, the capital cost would have to be in the neighborhood of $1000-$3000 per kW. Photovoltaic panels, at least at readily available consumer prices, correspond to an unreasonably long payback (around 18 years) for even the most optimistic assumptions on electricity prices and investment costs.