Confession, specifically the practice of confessing one's sins to a priest, is a quite common practice in the Catholic Church. When and how did this sacrament first originate and become codified as standard Catholic practice?
The "ear confession" as we know it today is an invention of Irish monks (some 6th century? I'm not sure). Before that time, only heavy sins (especially renouncing Christ) were confessed in front of whole congregation. Private confession allowed to confess all sins. This practice spread with Irish missionaries quickly. It was codified as mandatory (at least once a year) on IVth Lateran council (1215).
EDIT: wikipedia on the Sacrament of Penance (Catholic Church) focuses on penance, so the beginning of the practice of confession is bit obscured, but it gives further details and approves the codification in 1215.