Gram staining is derived from its inventor, Hans Christian Gram, a Danish bacteriologist. It was his method of staining bacteria that gained him international reputation in the field of bacteriology. His purpose of developing such method is to help in viewing bacteria under a microscope by staining them with dyes, i.e. crystal violet and safranin (or fuchsine).
Later on, gram staining became an essential method in classifying bacteria as either gram-positive or gram-negative. Gram-positive bacteria are those that retain the primary stain, i.e. crystal violet dye. Gram-negative bacteria are those that take the counterstain dye, i.e. safranin (pink colour).
Gram staining is done by preparing a heat-fixed smear of bacteria from slant of broth cultures onto a slide. The smear is stained first with the primary dye (crystal violet) for about a minute, and washed with tap water to remove excess dye. The slide is next flooded with Gram's iodine that act as a mordant. After one minute, the slide is washed with tap water, and then with 95% alcohol (about 30 seconds). To stop the decolorization, the slide is washed with tap water (for another 30 seconds). The slide is then flooded with the counterstain (safranin or fuchsine) for half a minute. After which, the slide is washed, drained, and blotted to be examined under the microscope.