Memory foam is made from polyurethane foam. It is specially manufactured using diisocyanate monomers and a polyol (multifunctional alcohol) and water. This mixture rises like dough rises into bread. It contains lots of bubbles created by gases that are introduced into the mixture. The sizes of the bubbles can be controlled by chemicals, and the mixture eventually sets into a foam that can be used to make a mattress.