Gel electrophoresis is a technique used for the separation of nucleic acids and proteins.
When a biological sample, such as proteins or DNA, is mixed in a buffer solution and applied to a gel, these two forces act together. The electrical current from one electrode repels the molecules while the other electrode simultaneously attracts the molecules. During electrophoresis, macromolecules are forced to move through the pores when the electrical current is applied. Their rate of migration through the electric field depends on the strength of the field, size and shape of the molecules, relative hydrophobicity of the samples, and on the ionic strength and temperature of the buffer in which the molecules are moving. After staining, the separated macromolecules in each lane can be seen in a series of bands spread from one end of the gel to the other.