From dairy farms failing to keep milk refrigerated to chickens suffocating en masse due to failing ventilators and undertakers struggling to preserve bodies, South Africa is buckling under its worst power crisis in years.

Africa's most industrialised nation has been hit by crippling blackouts, pushing thousands of consumers to take to the streets in protest this week.

Here's what you need to know about the crisis:

- Eight levels of misery -

The state-owned utility Eskom imposes blackouts, called load-shedding, when supply fails to meet demand.

There are eight levels of these scheduled cuts, with outages ranging from two-and-half hours to slightly more than 12 hours in total in a day.

This month, the blackouts have oscillated between stages three and six.

The last two stages have never been implemented but there has been a record number of stage-six days in recent months.

At such times, the power goes off for half a day, and only those with generators, solar panels or a wind turbine can get relief.

Mounting anger has led to several protests in recent days and lawsuits against the authorities.

Outages cost hundreds of millions of dollars in lost output each day, according to opposition estimates.

- How did South Africa get here? -

The crisis besetting Eskom has several causes.

The end of apartheid in 1994 was followed by a push to connect areas where the black majority previously had no mains electricity.

This, coupled with economic growth and a surging population, which has swelled from less than 45 million to 60 million, has fed demand.

In 2007, the year power cuts were first implemented, Eskom began building two new coal-powered stations to try to keep pace.

But older plants are plagued by breakdowns and are in constant need of maintenance.

And the new plants themselves have suffered from commissioning delays, design and construction problems, massive cost overruns and allegations of graft.

Eskom also blames its problems on sabotage, theft of coal and spare parts by organised gangs -- prompting the deployment of the military to guard the power plants.

The ailing monopoly has racked up debts of 400 billion rand debt ($23 billion), equivalent to nearly a quarter of South Africa's annual GDP.

Last year, it said it had run out of money to buy diesel, which it burns to make up for production shortfalls caused by breakdowns.

South Africa uses coal, which it has in abundance, to generate about 80 percent of its electricity.

It estimates it needs 1.5 trillion rand to switch out of fossil fuels. Last year it secured hundreds of millions of dollars in international funding to help transition to cleaner sources.

- Is there a solution? -

The government, which the opposition blames for the crisis, put forward a plan last July.

This includes improving maintenance, importing electricity from neighbouring countries and speeding the rollout of renewables, a process that has long been braked by protection for the coal industry, which employs almost 100,000 people.

A licensing threshold for private power generation projects has been removed and a pricing structure to let private firms sell electricity generated by rooftop solar panels is soon to be completed, President Cyril Ramaphosa said this week.

The president has warned the crisis cannot be solved overnight although some of his cabinet ministers have boasted it could be over in six to 18 months.

Bertha Dlamini, the head of non-profit African Women in Energy and Power, cautioned that renewables were gathering strength but "not fast enough to cushion the country" from blackouts.

"Load-shedding will be with us for a number of years, it may improve but it is less likely to go away completely for the next three years," she said.