A bushfire that threatened lives and homes in Gnangara in Perth's north has been downgraded to advice level after firefighters brought the blaze under control.

The Department of Fire and Emergency Services issued an emergency warning late on Saturday morning, but had the fire under control within hours.

It is believed the fire started on Sydney Road.

An advice level remains in place for people in an area bounded by Lake Gnangara, Steel Road, Joyce Road, Sydney Road, Stoney Road, Badgerup Road and Gnangara Road.

Emergency WA says there is no immediate danger, but people in or near the fire are urged to be aware and keep up to date.

The fire threatened homes and businesses around Sydney Road. ( ABC News )

Perth recorded a maximum temperature of around 39 degrees Celsius on Saturday.

A fire ban is in place across the most of the state and several national parks have been closed.