Electrolytes are substances that dissociate (separate) into electrically charged particles (ions) when in solution.
Positively charged ions are called cations and negatively charge ions are termed anions.
Anions - Bicarbonate, Chloride, Phosphorus
Cations - Calcium, Magnesium, Potassium, Sodium
Several pairs of oppositely-charged ions are closely linked in the body so that a disturbance in one ion affects the other. That is the essence of electrolytic balance/imbalance.
Sodium and chloride are linked this way, as are calcium and phosphorus.
In electrolyte solutions, even with multiple ion pairs, electrical neutrality is always maintained; this is called electroneutrality.
Extracellular
Sodium and chloride are the major electrolytes in extracellular fluid.
Intracellular
Potassium, phosphate and magnesium are the most abundant intracellular electrolytes.
Magnesium acts as a catalyst in myriad enzyme reactions; as such its role and importance is much greater than its physical quantity would indicate.
Electrolytic balance is extremely important, as imbalances can quickly lead to impaired functioning or death!