NOVELTY - Use of foams generated from an aqueous fluid, at least one gas and at least one surfactant in the production of oil and/or gas from subterranean formations penetrated by at least one injection well by providing an aqueous formulation comprising 0.05-5 wt.% surfactant capable of stabilizing foams and generating a foam of the aqueous formulation comprising surfactants and the gases is claimed.    USE - The foam is useful for: fracturing by injecting the foam through at least one well into the subterranean formation at a pressure sufficient to create fissures in the formation; foam drilling; and conformance control (all claimed).    ADVANTAGE - The foam enhances the oil recovery (claimed); and improves the sweep efficiency of the displacing fluid.    DETAILED DESCRIPTION - Use of foams generated from an aqueous fluid, at least one gas and at least one surfactant in the production of oil and/or gas from subterranean formations penetrated by at least one injection well by providing an aqueous formulation comprising 0.05-5 wt.% surfactant capable of stabilizing foams and generating a foam of the aqueous formulation comprising surfactants and the gases is claimed. The foam is generated at the surface and injected into the subterranean formation through at least one injection well, or the aqueous formulation and at least one gas injected successively, alternate or together into the subterranean formation through at least one injection well and foam is in-situ generated subsurface in the injection well and/or in the formation. The surfactants are substituted alkyl betaines of formula (I), substituted alkyl N-oxides of formula (II), amphoteric surfactants of substituted amines of formula (III), anionically modified alkyl ethers of formula (IV), substituted alkyl or alkenyl polyglucosides of formula (V), modified alkyl or alkenyl polyglucosides of formula (VI), and substituted alkyl sulfates of formula (VII).    R1 = 8-24C alkyl and/or alkenyl;    R2 = 1-4C alkyl;    R3 = 8-24C alkyl and/or alkenyl;    R4 = 1-4C alkyl;    R5 = R5a, R5b, or R5c;    R5a = 8-24C alkyl and/or alkenyl;    R5b = R8CO-;    R5c = R8CO-NHR9;    R5a = 8-24C alkyl and/or alkenyl;    R8 = 7-15C alkyl and/or alkenyl;    R9 = 1-4C alkylene;    R6, R7 = omega -carboxyalkyl of -(CH2)n-COOM, omega -hydroxyalkyl of -(CH2)n-OH;    R6c, R7c = -(CH2CH2-R10)m-R11-COOM;    M = H+, or a cation;    m = 1-10;    R10 = O, or NH;    R11 = 1-4C alkylene;    R12 = linear or branched 12-18C alkyl;    n = 1-5;    X- = -SO3-, -R13-SO3-, or R13-COO-;    R13 = 1-10C alkylene;    R15 = 8-22C alkyl or alkenyl;    G1 = 5-6C sugar unit;    p = 1-10;    R16 = R16a, or R16b;    R16a = 1-6C divalent hydrocarbon;    R16b = divalent ester -C(O)-OR17-;    R17 = 1-6C hydrocarbons;    q = 1-4; and    R18 = linear or branched 12-18C alkyl.