The Yoga Shikha Upanishad probably originated from the 13th century. This extract from the first chapter perhaps present the earliest known tantric view of Hatha yoga and Raja yoga. This Upanishad is also the oldest text in which the two terms are defined.

Upanishads

Raja yoga described as the union of male semen (Retas (रेतस्, Retas)) with female vaginal secretion (Rajas (रजस्, Rajas)) (YSU I.137).This interpretation of Raja yoga was often literally translated particularly in tantric Kaula (कौल, Kaula) schools. In other tantric traditions, Raja-Yoga (रजयोग, Raja-Yoga) is often translated as the union of Shiva (शिव, Śiva) and Shakti (शक्ति, Śakti), the male and female beings.Modern interpretations of the term Raja yoga usually gloss over these tantric ideas.