The blaze, near Mousaword Loch in Sandness, could have potentially damaged power supplies, the Scottish Fire and Rescue Service (SFRS) said.
The service was alerted to the incident at about 12:50 on Thursday and fire crews took just under two hours to bring it under control.
Firefighters from Walls, Scalloway and Lerwick were involved.
Incident commander Myles Murray said: "This was an extremely challenging wildfire involving a large area and the crews did a truly excellent job to extinguish it.
"Wildfires are inherently unpredictable and we knew that if the wind changed direction, the flames could threaten power lines supplying electricity to our communities, which would obviously have a very serious impact on homes and businesses."
He added: "Our crews had to operate in arduous conditions and it was a physically demanding operation, but their skill and professionalism ensured this fire was successfully extinguished before the power supply was threatened and more environmental damage done."
The wildfire came during a spell of warm, dry weather which saw the temperature in Braemar in Aberdeenshire reach 18.6C on Thursday.
The fire also flared up on the same day SFRS issued a warning to the public to be aware of the risk of wildfires.
Firefighters have tackled a wildfire covering about 70 acres (28ha) in Shetland.