Prayer is an invocation or act that seeks to activate a rapport with an object of worship through deliberate communication. In the narrow sense, the term refers to an act of supplication or intercession directed towards a deity a god , or a deified ancestor. More generally, prayer can also have the purpose of thanksgiving or praise , and in comparative religion is closely associated with more abstract forms of meditation and with charms or spells. Prayer can take a variety of forms: it can be part of a set liturgy or ritual , and it can be performed alone or in groups. Prayer may take the form of a hymn , incantation , formal creedal statement, or a spontaneous utterance in the praying person.