Vararuci (also transliterated as Vararuchi) ( Devanagari: वररुचि) is a name associated with several literary and scientific texts in Sanskrit and also with various legends in several parts of India. This Vararuci is often identified with Kātyāyana. Kātyāyana is the author of Vārtikās which is an elaboration of certain sūtrās (rules or aphorisms) in Pāṇini's much revered treatise on Sanskrit grammar titled Aṣṭādhyāyī. Kātyāyana is believed to have flourished in the 3rd century BCE. However, this identification of Vararuci with Kātyāyana has not been fully accepted by scholars. Vararuci is believed to be the author of Prākrita Prakāśa the oldest treatise on the grammar of Prākrit language. Vararuci's name appears in a verse listing the 'nine gems' ( navaratnas) in the court of one King Vikrama. Vararuci appears as a prominent character in Kathasaritsagara ("ocean of the streams of stories"), a famous 11th century collection of Indian legends, fairy tales and folk tales as retold by a Saivite Brahmin named Somadeva.
Vararuci is the father figure in a legend in Kerala popularly referred to as the legend of the twelve clans born of a pariah woman (Parayi petta panthirukulam). Vararuci of Kerala legend was also an astute astronomer believed to be the author of Chandravākyas ( moon sentences), a set of numbers specifying the longitudes of the Moon at different intervals of time. These numbers are coded in the katapayādi system of numeration and it is believed that Vararuci himself was the inventor of this system of numeration. The eldest son of Vararuci of Kerala legend is known as Mezhathol Agnihothri and he is supposed to have lived between 343 and 378 CE.
The name Vararuchi is associated with more than a dozen works in Sanskrit, and the name Katyayana is associated with about sixteen works. There are around ten works connected with astronomy and mathematics associated with the name of Vararuci.