# Are Monoids a category inside a category?

Looking at the definition of Monoids, it looks like they are an object inside a category with one object. I have also noticed that they have operations like composition and identity which must be associative. Is a monoid a kind of category hidden in an object of another category?

-
A monoid can be thought of as a category with exactly one object. This way they can be considered to be full subcategories of a given category. Completely determined by the choice of the unique object. –  drhab Feb 6 '14 at 11:30
see also my answer: math.stackexchange.com/questions/421215/… –  Oskar Feb 6 '14 at 19:03

• To every monoid $M$ we can associate a category $BM$ with exactly one object $\star$ and $\mathrm{End}_{BM}(\star)=M$. The identity and composition comes from $M$.
• Given a category $C$ and an object $x \in C$, then $\mathrm{End}_C(x)$ is a monoid.
There's nothing inside the object: the identity and composition show up in the morphisms of the object of the category associated to $M$. –  Kevin Carlson Feb 6 '14 at 11:27