A cofactor is a non-protein chemical compound or metallic ion that is required for the biological activity of an enzyme. These molecules can be essential for the enzyme's function, aiding in the catalytic process by stabilizing enzyme-substrate interactions or participating in the chemical reactions. Cofactors can be divided into two main categories: organic cofactors, known as coenzymes, and inorganic cofactors, which include metal ions.