The ONGC said there was no impact on oil processing and that the gas was diverted to its Hazira plant in Surat district of Gujarat.
The blaze erupted around 7 am in a processing plant of the ONGC located in Uran area of neighbouring Navi Mumbai, the police said.
"Four people have been killed and three others injured in the mishap," a senior police official said.
"Fire broke out in storm water drainage in Uran Plant early morning successfully doused within two hours by fire fighting team. #ONGCs robust crisis mitigation preparedness helped put off this major fire in a very short time," the ONGC said in a tweet.
Earlier, in another tweet, it said, "A fire broke out in storm water drainage early morning 2day in Uran oil & gas processing plant.ONGC fire services & crisis management team immediately pressed in2 action. Fire is being contained. No impact on Oil processing.Gas diverted to Hazira Plant. Situation is being assessed.
Nearly 22 fire brigade tenders, including that of the ONGC, Navi Mumbai civic body and other agencies, were at the spot, the police official said.
The injured persons were admitted to nearby hospitals for treatment, he said.
The cause of the fire was yet to be ascertained, he added.