The identity morphism, or simply identity, of an object in some category is the morphism , or , which acts as a two-sided identity for composition.
Given a small category with set of objects and set of morphisms , the identity assigning function of is the function that maps each object in to its identity morphism in .
For the generalisation to an internal category , see identity-assigning morphism.
In Set, the identity morphisms are the identity functions.