There are fears a "mega-fire" at Gospers Mountain could tear through a coal mine and a major power station north west of Sydney this week, as temperatures soar to 46 degrees Celsius.

NSW is expected to swelter through a heatwave on Thursday and Saturday

NSW is expected to swelter through a heatwave on Thursday and Saturday A statewide fire ban will apply from midnight Wednesday to midnight Saturday

A statewide fire ban will apply from midnight Wednesday to midnight Saturday Fire is threatening a power station near Lithgow that supplies 10 per cent of the state's electricity

Firefighters spent Tuesday putting embers out around the Mount Piper power station near Lithgow before the NSW Rural Fire Service (RFS) declared a statewide total fire ban from midnight tonight until midnight on Saturday.

Hot and windy conditions are expected at many locations around the state in that period, with temperatures over 45C forecast.

RFS Deputy Commissioner Rob Rogers said fire reaching the power station, the Springvale Coal Mine or the abandoned Wallerawang coal mines was "the last thing" crews needed.

"A lot of crews were deployed near that power station just to make sure the fire did not get into the coal," he said.

"The last thing we need is something like that going."

The Gospers Mountain fire was downgraded to advice level before 11:00pm.

The RFS is closely monitoring the Gospers Mountain "mega fire". ( Supplied: Gena Dray )

The Mount Piper Power Station generates around 10 per cent of the state's electricity and there is concern the fire could threaten power supplies in the region.

The Springvale coal mine has been closed since Thursday last week due to the risk of fire but Centennial Coal, which owns the mine, said the facility's stockpiles of coal were well protected behind containment lines.

"We are well prepared and well supported by the RFS and Fire and Rescue," spokeswoman Katie Brassil said.

"We lost power to the mine last night which means there has obviously been some damage to infrastructure."

Ms Brassil said the facility had been forced to close, in part, because smoke had been sucked deep into the mine through the ventilation shafts.

Greenpeace Australia Pacific warned that if the fire took hold in the coal stockpiles it could burn for weeks and emit toxic fumes that would aggravate air pollution across Sydney and NSW.

The last time a coal mine fire took hold was in 2014 at the Hazelwood coal mine in Victoria.

The Springvale Coal Mine is shrouded in bushfire haze from nearby Ben Bullen's blaze. ( ABC News: Donal Sheil )

Spokesman Jamie Hanson said that fire burned for 45 days and produced toxic chemicals such as carbon monoxide and nitrogen oxide.

A 'monster' fire

United States forestry worker Linda Chappell is spending more than a month in Australia helping firefighters, working as a strategic operations planner on the Gospers Mountain fire.

Ms Chappell said the fire was a "monster" but spending her Christmas in Australia was a chance to give back.

"We've had to have help from Australia before and my husband and I spoke about it and he said 'boy they've showed up when you needed help and I said yep and he said let's go', and so we're paying it back," she told the ABC.

The RFS is bracing for a heatwave and strong winds that are expected to sweep through NSW on Thursday and Saturday.

Very hot and dry conditions and an elevated fire danger are being forecast for parts of Sydney.

Space to play or pause, M to mute, left and right arrows to seek, up and down arrows for volume. Watch Duration: 1 minute 30 seconds 1 m 30 s Gospers Mountain mega-fire flares up in Blue Mountains

Penrith is expected to be one of the hottest parts of the state with 44C forecast for Thursday and up to 46C predicted on Saturday.

Lithgow, where the Gospers Mountain blaze is burning, is predicted to reach 37C on Thursday and 39C on Saturday and parts of far western and southern NSW will reach well into the mid-40s.

The Gospers Mountain fire has already burnt through almost 400,000 hectares in multiple directions, and the RFS said it was likely to burn for "some weeks".