The membrane potential is primarily generated by the unequal distribution of ions across the cell membrane and the selective permeability of the membrane to these ions. The most important ions involved are sodium (Na+), potassium (K+), chloride (Clâ), and calcium (Ca2+). The sodium-potassium pump plays a key role by actively transporting Na+ out of the cell and K+ into the cell.