How salts are prepared?

Principally salts are the products of reactions between acids and bases.