The present invention relates to a container comprising a first chamber containing a foamable liquid; a self-heating element which is in thermal contact with the foamable liquid; a pressurized gas which is contained in the first chamber or in a second chamber allowing release of the pressurized gas to the first chamber; and an outlet valve which is in liquid communication with the first chamber. The container and/or the outlet valve can be used for dispensing foam and aerated liquid, preferably milk foam. Preferably, the foamable liquid is milk, preferably dairy milk or plant based milk, more preferably pasteurized and/or sterilized dairy milk.