Without a formal creed, set of rituals or obligations – unless you count the discipline of a regular practice – yoga has never been a religion in its own right.
However, yoga does have roots in the contemplative practice of Jainism, Buddhism and most especially Hinduism.
It's first described in the Upanishads (800 BCE - 500 BCE) as a meditation technique to strip away the layers separating us from our own true self, or Atman, so that we may perceive ourselves as drops of water in the ocean that is Brahman, the universal spirit.
In modern times, especially the past fifty years, and especially in the West, the focus has been almost entirely on the physical practice and yoga, like many elements of society, has become entirely dissociated from any religious intent.
And yet, significant numbers of those who initially come to yoga for the physical often develop a very different view of themselves, both as an individual and in relation to others, that harks back to those contemplative roots. Many experience an evolution in perceived purpose and values that leads to profound life changes.
In this sense, even though the modern branches of yoga are no longer religious, yoga remains true to its contemplative roots – helping us strip away the layers that separate us from our true nature; revealing a new sense of Self and a new sense of our place in the world.
Read more History of Yoga