Wiki article on this topic:
Soap is the term for a salt of a fatty acid or for a variety of cleansing and lubricating products produced from such a substance. Household uses for soaps include washing, bathing, and other types of housekeeping, where soaps act as surfactants, emulsifying oils to enable them to be carried away by water. In industry, they are used as thickeners, components of some lubricants, and precursors to catalysts.
Since they are salts of fatty acids, soaps have the general formula nMn+. The major classification of soaps is determined by the identity of Mn+. When M is Na or K, the soaps are called toilet soaps, used for handwashing. Many metal dications give metallic soap. When M is Li, the result is lithium soap , which is used in high-performance greases.
Soaps are key components of most lubricating greases and thickeners. Greases are usually emulsions of calcium soap or lithium soap and mineral oil. Many other metallic soaps are also useful, including those of aluminium, sodium, and mixtures thereof. Such soaps are also used as thickeners to increase the viscosity of oils. In ancient times, lubricating greases were made by the addition of lime to olive oil.
Metal soaps are also included in modern artists' oil paints formulations as a rheology modifier.
Most heavy metal soaps are prepared by neutralization of purified fatty acids:
In a domestic setting, "soap" usually refers to what is technically called a toilet soap, used for household and personal cleaning. When used for cleaning, soap solubilizes particles and grime, which can then be separated from the article being cleaned. The insoluble oilfat molecules from the water making it soluble. Anything that is soluble will be washed away with the water.
The production of toilet soaps usually entails saponification of fats. Triglycerides are vegetable or animal oils and fats. An alkaline solution induces saponification whereby the triglyceride fats first hydrolyze into salts of fatty acids. Glycerol is liberated. The glycerin can remain in the soap product as a softening agent, although it is sometimes separated.