Renewable energy has historically been costlier than fossilized energy. This is changing now.
Lazard’s latest annual report on Levelized Cost of Energy Analysis highlighted that certain renewable energy technologies are becoming cost-competitive vis-à-vis conventional energy technologies. For example, see the chart below.

Source: Levelized Cost Of Energy, Levelized Cost Of Storage, and Levelized Cost Of Hydrogen
Crystalline-based and thin film-based solar energy generation, and wind energy generation are cheaper than coal-based energy generation. Moreover, their cost-competitiveness increase further after including government subsidies. Solar energy, under certain circumstances, is perhaps the most cost-competitive that any other form of usable energy in history.
However, we cannot switch to renewable sources quickly.
Countries around the world have built entire ecosystems around fossil fuel. All the associated infrastructure that have been developed over multiple decades cannot be replaced in a few years.
For instance, a CNBC report highlighted the findings of Banking on Climate Chaos 2021 that sixty of the largest banks in the world have invested $3.8 trillion in fossil fuels between 2016 and 2020. While fossil fuel financing decreased in 2020 as compared to the previous year, it is still higher than 2016, the year just after the Paris Climate Agreement was signed (see the image below.)

Source: Banking on Climate Chaos
Carbon-intensive sectors have been playing a huge role in driving global economic development for over a century now. While many companies have set long-term plans for achieving net-zero emissions, this reduction of their current carbon footprints is expected to be a slow and complex process. Furthermore, the social cost of greenhouse gas emission (e.g., the cost of each ton of carbon-dioxide that is emitted today) is yet to be accurately quantified and universally accepted as a measurement tool. As a result, these costs seldom make it to the balance sheets of companies, and thus, are often not reflected in their strategic goals.
As more R&D investments flow into the renewable energy sectors, the pace of technological innovations accelerate, and the advantages of scale start taking effect, the practical feasibility of large-scale clean energy generation will continue to increase.