Here's a breakdown:
* Sanskrit: It's the ancient language of India, considered the root of many modern Indian languages. Hindi borrows heavily from Sanskrit for its vocabulary, grammar, and religious terminology.
* Prakrit: These were a group of vernacular languages that evolved from Sanskrit and were widely spoken in ancient India. Hindi emerged from a specific group of Prakrit languages known as Apabhramsha.
So, while Sanskrit is the ultimate ancestor, Hindi's immediate source is the Apabhramsha Prakrit languages.