TOKYO -- China has come to dominate worldwide solar and wind energy generation, in terms of both its own capacity and its companies' share of global markets, leaving previous powerhouses -- particularly the U.S. and Japan -- to play catch-up.

In an office building in Shanghai, dozens of workers employed by Envision Group, the world's fifth-largest wind turbine maker, oversee a network encompassing 100 gigawatts of power generation capacity -- equivalent to all of Japan's renewables.

Envision's system links tens of millions of devices, including electric-vehicle chargers, elevators and room temperature sensors. Data from this equipment is used to estimate energy demand, letting the system determine how to distribute the electricity from Envision's plants. The company can also use it to spot signs of potential trouble at power facilities.

China's wind power capacity soared 22-fold and solar nearly 700-fold in the decade through 2018, according to data from the International Renewable Energy Agency, or IRENA. This was the main driver behind global wind capacity quintupling and solar surging 33-fold over the same period. China accounted for about 30% of the world's renewables last year, with the U.S. a distant second at 10%.

Renewables form a centerpiece of Chinese President Xi Jinping's "Made in China 2025" industrial modernization plan that seeks to make Beijing the world leader in the high-tech sector. Since meeting the nation's growing energy needs with fossil fuels would exacerbate an already serious air pollution problem, the government aims to increase the total share of solar and wind in the overall power mix to nearly 30% in 2030 from less than 10% last year.

The Belt and Road infrastructure initiative has helped power China's renewables sector as well, giving businesses opportunities to export clean-energy technology and take on large-scale electricity projects in emerging countries.

If the world moves toward renewable energy, China's influence could rise as resource-exporting countries ebb, IRENA wrote in a January report.

A 250 km-long hub of manufacturers producing solar panels and materials, including silicon components, glass and cables, sits outside Shanghai. Longi Solar, the world's No. 6 panel maker, operates a massive factory there that could meet 70% of Japan's total demand. Chinese players controlled 71% of the panel market in 2017, while Japan -- once in the lead -- was down to a mere 2%.

While the wind turbine market remains more divided, two of the top five players are Chinese, holding a 22% share between them as of last year. The other three are split across Denmark, Spain and the U.S.

China's rapid pivot to renewables, and its ambitions for foreign markets, are among the roots of trade tensions with the U.S.

Washington imposed a safeguard tariff on photovoltaic modules in early 2018, citing fears that its domestic solar industry would disappear. Panel prices had tumbled 60% over the four years through 2016, and even First Solar, the country's largest panel maker, was losing money.

But the global solar industry would not be viable without China. India, which introduced a safeguard duty on Chinese and Malaysian solar imports in July 2018, has ended up with an influx of panels from plants run by Chinese manufacturers in other Southeast Asian countries.

"Expanding our sales channels overseas has proved effective," said Dany Qian, vice president of global market leader JinkoSolar Holding.

In China, solar costs have come down "nearly to a point where it could gain ground even without subsidies," said Li Junfeng of China's National Center for Climate Change Strategy and International Cooperation.

Reaching that level will be important to China from an energy security standpoint. The country relied on imports for 60% of its oil in 2015.

China's renewables industry is establishing technological dominance to match its grip on the global market. The country moved into the lead in applications for renewable-energy-related patents in 2009, surpassing Japan, and it held roughly 170,000 as of 2016 -- 60% more than the U.S. and double Japan's total. Chinese companies have also taken the lead in power management systems in factories and offices.

The current U.S. government has not been nearly as supportive of green energy as Beijing, with President Donald Trump withdrawing America from the Paris climate accord. But technology companies such as Google have broken with Washington and embraced renewables, bringing down power-generation costs for green energy.

Japan gets 8% of its power from renewable sources, not including hydroelectric. The government's feed-in tariff system had helped solar gain traction, but the country's share of panel production has fallen sharply, and other renewables such as wind have yet to make much headway.