Soaps are substances used with water, for cleaning and washing and are made from a compound of vegetable oils or animal fats along, with sodium or potassium hydroxide and generally have perfumes or colourants, added to it.
Whereas
Detergents are synthetic water soluble cleaning agents that unlike soap (which are prepared from vegetable oils or fats) are prepared from petroleum products along with sodium or potassium hydroxide.
Detergents have an advantage over ordinary soap
1. Hard water is one which does not lather with soap, while soft water lathers easily.
2. Ordinary soap when rubbed in hard water is wasted and lather forms only after all the insoluble salts in hard water are removed as scum.
3. Synthetic detergents do not form scum and lather even in hard water.