Salts most commonly form through a neutralization reaction, in which an acid reacts with a base to produce a salt and water. The reaction releases heat because forming the strong ionic bonds in a product like NaCl, along with a stable water molecule, is energetically favorable.
In their dry, solid state, salts arrange into a rigid, repeating pattern called a crystal lattice, which makes them hard and brittle with high melting points. When a salt dissolves in a polar solvent like water, or when it melts, its lattice breaks apart into freely moving ions.
These free ions let the solution or melt conduct electricity, which is why salts are classified as electrolytes. Sodium chloride, ordinary table salt, is the most familiar example, but the term salt covers an enormous range of compounds, from baking soda to the calcium salts found in bone.
A salt’s acidity or basicity in solution depends on the strength of the acid and base that formed it. Some salts, called hydrates, even trap water molecules within their crystal structure, such as copper(II) sulfate pentahydrate, which is blue, compared to the white anhydrous form.

