A hymn, in its shortest (and earliest) definition, is a song of praise to God.
In the Christian context, hymns have been used in worship since the 4th century. St. Ambrose’s Te Deum – “We praise thee O God: we acknowledge thee to be the Lord” - comes from this time. The first hymnals were gathered about the 12th – 13th centuries and, during the rest of the Middle Ages and into the Renaissance’ the form followed the styles of other sacred music of the time.
Following the Reformation, we can add at least two criteria to the definition above.
Hymns began to be written for the congregation to sing – first in German Lutheran services (Martin Luther himself was a fine composer) where chorales became a large part of congregational worship, then later in England where the modern hymn would be developed after a period where the domination of Calvinist dislike of such drollery brought about a form of hymn based on Psalms. Whilst much more severe and restrained than the German chorales, these “metrical psalms” were immensely popular. Some still are.
Hymns now had to be in the vernacular – that is in the language of the congregation. This is the second of the two criteria mentioned above.
The non-conformist reformers of the mid 18th century, such as John and Charles Wesley used hymns as a way of attracting adherents in their great open-air meets. Hymns were written that were singable, easy to remember, simple in form but melodic. Like carols, folksongs, spirituals, and other types of “popular” music, they became, like these forms, almost invariably strophic; that is in the form of repetitive verses, with or without a line or two of chorus at the end of each verse. The congregation were participating. Finally. Not just in a formal liturgical response to a formal liturgical verse. They could raise the roof... bellow their hearts out. The established church replied in kind and, during the next 150 years, most of the hymns that are part of the fabric of Western society were written. A congregation can now worship on equal footing with the priest or vicar or pastor because of this.