The ultimate goal of Yoga is liberation or what many will call “moksha”.
The term “yoga” itself, has been applied to a variety of practices and methods, and can be found in teachings of Buddhism as well. However, in Hinduism the practice of yoga itself pertains to Jnana Yoga, Bhakti Yoga, Karma Yoga, Laya Yoga and Hatha Yoga.
Raja Yoga is the path of self discipline and practice to encourage fearlessness and confidence. Commonly referred to as Ashtanga Yoga, which references the eight limbs (eight steps) to be practiced to attain samadhi. Raja Yoga was first references as Royal Yoga when it was first tied to the Yoga Sutras of Pantajali, though mystics call it adhyatma yoga. It is a path that can be practiced by anyone and uses the open eye method.
There is ongoing discussions on the chronology and origins of yoga and many of its teachings, but most will agree that it was originally developed in ancient India though some of the teachings are often found in Buddhism as well.