Gram staining (or Gram's method) is a method of differentiating bacterial species into two large groups (Gram-positive and Gram-negative).
It is based on the chemical and physical properties of their cell walls. Primarily, it detects peptidoglycan, which is present in a thick layer in Gram positive bacteria. A Gram positive results in a purple/blue color while a Gram negative results in a pink/red color.
The Gram stain is almost always the first step in the identification of a bacterial organism, and is the default stain performed by laboratories over a sample when no specific culture is referred.
While Gram staining is a valuable diagnostic tool in both clinical and research settings, not all bacteria can be definitively classified by this technique, thus forming Gram-variable and Gram-indeterminate groups as well.
The word Gram is always spelled with a capital, referring to Hans Christian Gram, the inventor of Gram staining.