The first indications of devotion to the Sacred Heart of Jesus can be found in the Benedictine and Cistercian monasteries in the early 11th and 12th centuries. The earliest hymn to the Sacred Heart of Jesus was written by the Norbertine Blessed Herman Joseph in 1241 (the Summi Regis Cor Aveto). One of the great precursors to the devotion of the Sacred Heart was Saint Lutgarde and her miraculous visions. In one, Jesus came to her and offered her any gift of grace that she wanted - she asked only for a better understanding and fluency of Latin so that she could better understand the Word of God. Immediately she was flooded with psalms, antiphons, readings, etc. but she found a great emptiness still persisted in her heart. When she asked to return the gift, Christ asked her what she would exchange it for. She said:
"Lord, I would exchange it for your Heart."
Saint Mechtilde was another strong devotee of the Sacred Heart of Jesus. She reported that she too had miraculous visions, specifically one in which Christ came to her and commanded that she love him ardently and that she honor his sacred heart in the Blessed Sacrament to her greatest efforts. The most significant early devotee though was Saint Margaret Mary Alacoque, a nun of the Order of the Visitation of Holy Mary. On December 27th, 1673, the Feast of Saint John the Evangelist, Saint Margaret had the first of several visions in which Christ came to her. At the final vision, he told her the specifics of the devotion - Holy Communion on the First Friday of each month, Eucharistic adoration on Thursdays and the celebration of the Feast of the Sacred Heart.
The first special Mass honoring the Sacred Heart of Jesus was instituted in 1353 by Pope Innocent VI. In 1693, following the death of Saint Margaret Alacoque, indulgences were imparted to the Confraternities of the Sacred Heart and in 1697 a feast granted to the Visitandines with the Mass of the Five Wounds. Several cities in Europe began to celebrate a feast and Mass for the Sacred Heart and in 1856 Pope Pius IX extended the feast and Mass to the entire Latin church as a double major. It was raised in 1889 to a double rite of the first class. Pope Leo XIII's encyclical Annnum Sacrum decreed that the consecration of the entire human race to the Sacred Heart of Jesus should take place on June 11, 1899, that all Catholics should promote the First Friday Devotions, established June as the Month of the Sacred Heart of Jesus and included the Prayer of Consecration to the Sacred heart.
Pope Pius X followed this by decreeing that the consecration performed by Pope Leo XIII should be reconsecrated each year and affirmed Saint Margaret Alacoque's visions by stating that Jesus had manifested himself to her and had promised her that all those who rendered this honor to his Heart would be endowed with an abundance of heavenly graces. Today the Feast of the Sacred Heart is a solemnity and falls 19 days after Pentecost, on a Friday. The most famous depiction of the image of the Sacred Heart of jesus was painted by Pompeo Batoni.