Dorset Fire and Rescue was called to the incident in Victoria Avenue, shortly before 09:30 BST.
Residents have been told it is unlikely they will be able to return home until Wednesday morning. A rest centre has been opened at a nearby church hall.
Purbeck District Council said it arranged hotel accommodation for some older residents and people with health concerns.
About 100 residents are thought to have been affected.
At least nine people are known to have attended the rest centre at the United Reformed Church Hall in the town’s High Street and residents were being diverted there as they returned from work.
Council officers and social services teams are at the centre to help anyone who has been displaced.
The Women’s Royal Voluntary Service is providing food and drink for people unable to make alternative arrangements.
Residents are being accompanied by gas board officers to collect overnight belongings from their homes.
Transco workers are carrying out repair work while the fire service has set up three water jets as a precautionary measure.
The Swanage heritage steam railway was temporarily suspended but diesel trains were able to resume from 12:00 BST.