The recorded history of Andhra Pradesh, one of the 28 states of 21st-century India, begins in the Vedic period. It is mentioned in Sanskrit epics such as the Aitareya Brahmana (800 BCE). Its sixth-century BCE incarnation Assaka lay between the Godavari and Krishna Rivers, one of sixteen mahajanapadas (700–300 BCE). The Satavahanas succeeded them (230 BCE–220 CE), built Amaravati, and reached a zenith under Gautamiputra Satakarni.

After the Satavahanas, the region fragmented into fiefdoms. By the late second century CE, Andhra Ikshvakus ruled along the Krishna River. In the fourth century CE, the Pallava dynasty ruled southern Andhra Pradesh and Tamilakam, and had a capital at Kanchipuram. Their power increased in the reigns of Mahendravarman I (571–630) and Narasimhavarman I (630–668), and dominated northern Tamilakam and the southern Telugu-speaking region until the end of the ninth century.Northern Andhra Pradesh was under Vengi Chalukyas starting from 624 CE. Later during 1002 CE Vengi Chalukyas became subordinate to the Imperial Cholas when Rajaraja Chola I helped Vengi Chalukyas to secure the Vengi throne from Telugu Chola king Jata Choda Bhima. From 1002 CE till 1206 CE Andhra Pradesh was under Imperial Cholas.

From 1206 CE to 1323 CE the Kakatiya dynasty unified the land and in that golden age Tikkana’s translation of the Mahabharata founded Telugu literature. In 1258 CE, Pandyan emperor Jatavarman Sundara Pandyan I defeated Nellore Cholas and Kakatiyas, extending the Pandyan empire as far as Nellore. Kakatiyas unified the Andhra again during internal crisis in Pandyan empire. In 1323 CE, Ghiyath al-Din Tughluq, sultan of Delhi, sent a large army under Ulugh Khanlater Muhammad bin Tughluq, the Delhi sultan to lay siege to Warangal. After the Kakatiya dynasty fell, the Delhi Sultanate, and the Persio-Tajik sultanate of central India competed for the region. Reddi Kingdom (1325-1448) emerged under Prolaya Vema Reddy and successors ruled parts of this region in the early 14th century to mid 15th century, ruled over 120 years. Reddy kings constructed Kondaveedu Fort and Kondapalli Fort. Reddy kings ruled entire Coastal Andhra and parts of Tamil Nadu between 1325-1448. In the end the Musunuri Nayaks won over Delhi.

Under Krishnadevaraya of the Vijayanagara Empire (1336 CE–1646 CE) the Telugus became independent, then the Qutb Shahi dynasty ruled the Bahmani Sultanate there from the early 16th to the end of the 17th centuries, and was tolerant of Telugu culture.

The French, under the Marquis de Bussy-Castelnau, and the English, under Robert Clive, altered the regional polity. In 1765 CE, Clive and the chief and council at Visakhapatnam obtained the Northern Circars from Mughal emperor Shah Alam. The British later defeated Maharaja Vijaya Rama Gajapati Raju of Vizianagaram, in 1792 CE.

Andhra State was created in the year 1953 CE. Potti Sriramulu had campaigned for a state independent of the Madras Presidency, and Tanguturi Prakasam Pantulu's social-reform movements led to the founding of Andhra State, with a capital at Kurnool and freedom-fighter Pantulu as its first chief minister.

India became independent in 1947. The Nizam of Hyderabad, Mir Osman Ali Khan, wanted to remain independent, but in 1948 the Indian Army annexed Hyderabad to the Dominion of India, where it became Hyderabad State. Andhra Pradesh, the first Indian state formed primarily on the basis of language post independence, split off from the Madras Presidency in 1953. Andhra State merged with the Telugu-speaking portion of Hyderabad State in 1956 to create the state of Andhra Pradesh. Neelam Sanjiva Reddy became the first Chief Minister of Andhra Pradesh.

The Lok Sabha formed Telangana from ten districts of Andhra Pradesh on 18 February 2014.

Pre-Satavahana period

Chalcolithic age The Chalcolithic period is dated using pottery and is believed to be around 1750 BC or earlier. The pottery used for dating the time period was discovered from sites near the Krishna and Tungabhadra rivers such as Patapadu. A painted spouted vessel found there resembles chalcolithic-age vessels from Navdatoli and as far as Bronze Age Crete.

Proto-Historic and Historic periods

The term Andhra was first mentioned as the name of a tribe in the Aitareya Brahamana, datable to 800 B.C. Andhras left the north of the Indian subcontinent near the Yamuna river, crossed the Vindhyas and came to present-day Andhra Pradesh and Telangana. It also mentions that the Andhras were socially parallel to other tribes like the Pundras, Sabaras and Pulindas. There are references to an Andhra kingdom and a people known as the Andhras in Indian epic poetry (the Mahabharata, the Ramayana and the Puranas). In the Mahabharata Rukmi ruled the Vidarbha Kingdom, which included the Deccan Plateau, the foothills of the Vindhya Range, present-day Andhra Pradesh, Maharashtra, Madhya Pradesh and Karnataka and a little-known (now submerged) archipelago in the Bay of Bengal. Rama is said to have lived in the forest around present-day Bhadrachalam during his exile.

Ancient literature indicates a history dating to several centuries BCE, but archaeological evidence exists only from the last two millennia. The fifth-century Kingdom of Pratipalapura, identified with Bhattiprolu in the Guntur district of Andhra Pradesh, may have been the earliest kingdom in South India. Inscriptions suggest that King Kubera ruled Bhattiprolu around 230 BCE.

The script of the Bhattiprolu inscriptions was the progenitor of the Brahmi lipi, which later diversified into modern Telugu scripts.The Blackwell Encyclopedia of Writing Systems by Florian Coulmas, p. 228; Salomon (1998), p. 40.

Middle Kingdoms (3rd century BCE - 12th century CE)

Satavahana dynasty

As part of the Mauryan Empire during the fourth century BCE, Andhra was a political state in the southeastern Deccan. According to Megasthenes, who visited the court of Chandragupta Maurya (322–297), the Andhras had 30 fortified towns along Godavari River and an army of 1,00,000 infantry, 2,000 cavalry and 1,000 elephants.Megasthenes and Arrian, McKindle J. W. (ed. and trans.) Ancient India Thacker and Spink, Calcutta and Bombay, 1877, p. 30-174. The military might of Andhras was second only to the Mauryas.

Uninterrupted political and cultural accounts of Andhra Pradesh begin during the rise of the Satavahana dynasty. According to the Matsya Purana, the dynasty had 29 rulers in a 456-year period from the second century BCE to the second century CE. An inscription at Nasik, written at the time of Gautamiputra Satakarni (the 23rd Satavahana ruler), indicates that the kingdom included most of the southern peninsula and southern parts of Maharashtra, Orissa and Madhya Pradesh. The court language used by the Satavahanas was Prakrit, and their kings observed the Vedic religion.

The fall of the Satavahana empire left Andhra in political chaos, and local rulers carved out small kingdoms for themselves. Between 180 and 624 CE, control of Andhra lay with the Ikshvaku, Bruhatpalayana, Salankayana, Vishnukundina, Vakataka, Pallava, Ananda Gotrika, Kalinga and other small kingdoms; the most important was Ikshvaku. Sanskrit replaced Prakrit as the inscriptional language at this time.

Ikshvakus

The Andhra Ikshvakus (Sanskrit: इक्श्वाकू) established a kingdom along the Krishna River in the second half of the second century CE. Their capital was Vijayapuri (Nagarjunakonda). Archaeological evidence indicates that the Ikshvakus succeeded the Satavahanas in the Krishna River valley and may have entered Andhra from the north.Buhler and Rapson The Ikshvakus left inscriptions at Nagarjunakonda, Jaggayyapeta, Amaravati and Bhattiprolu, and their rulers observed the Vedic religion.

Some historians believe that Andhra Ikshvakus were related to the mythological Ikshvakus, while some believe Andhra Ikshvakus to be a local tribe who adopted the title.Ancient India, A History Textbook for Class XI, Ram Sharan Sharma, National Council of Educational Research and Training, India, pp. 212 Some scholars believe that this dynasty was related to the ancient Ikshvakus of the Hindu epics, and Rama of the Ramayana, the incarnation of Vishnu, was descended from the Ikshvaku line. Inscriptions in the Nagarjunakonda valley, Jaggayyapeta and Ramireddipalli provide some support for this hypothesis.

In the Vayu Purana, Manu (the patriarch of ancient India) had nine sons; Ikshvaku, the eldest, founded the Suryavamsha dynasty and ruled from Ayodhya at the beginning of the Treta Yuga. He had 100 sons; the eldest was Vikushi, who succeeded his father as the ruler of Ayodhya. Fifty of Vikushi's brothers founded small principalities in North India, and forty-eight founded kingdoms in the south. In the Dharmamrita, during the lifetime of the 12th tirthankara, Yasodhara (an Ikshvaku prince from the kingdom of Anga) went to Vengi. The prince was so impressed with the region's beauty and fertility that he made it his home and founded the city of Pratipalapura (present-day Bhattiprolu).

In the Puranas, the Andhra Ikshvakus are called Sriparvatiyas (rulers of Sriparvata) and Andhrabhrityas (servants of the Andhras). They were feudal lords of the Satavahanas, and bore the title of Mahatalavara. Although the Puranas cite seven kings ruling Andhra for 100 years, only four are confirmed in inscriptions.

Vashishthiputra Sri Santamula (Santamula I) Santamula I founded the Ikshvaku dynasty, performing the Ashvamedha, Agnihotra, Agnistoma and Vajapeya yagnas to proclaim his imperial status. Rulers of subsequent dynasties commonly performed the Ashvamedha yagna to declare their independence.

Virapurushadatta Virapurushadatta was the son and successor of Santamula through his wife, Madhari. He had a sister, Adavi Santisri, took a queen from the Saka family of Ujjain and gave his daughter in marriage to a Chutu prince.

Ehuvula Santamula (Santamula II) Ehuvula Santamula (Santamula II), Virapurushadata's son, ruled after a short Abhira interregnum.

Rudrapurushadatta Rudrapurushadatta was an Ikshvaku ruler mentioned in inscriptions from Gurajala in Guntur district. Possibly a son of Ehuvula Santamula, he ruled for over 11 years.

Bruhatpalayanas During the third century CE, the Bruhatpalayanas ruled northern Andhra from their capital, Kodur, in the Krishna district.

Anandagotrikas The Ananda Gotrikas (335–425) ruled coastal Andhra from their capital, Kapotapuram. Their affiliations are unknown. A few Anandagotras families have been discovered in the Anantapur district and Kadiri taluk. It is an old Kadapa district: Hiranya Raajya, in the Puranas. Anandagotras live in Cedaranya of Kadhiri area hill/mountain places called Batrapalli forest, Gogannapeta, Pandava Raju hill and Vankapalli. Old andha/kandarapuram have been demolished. Kambamraayudu mountain hill areas' surname is tatam in patras.

Salankayanas From about 300 to 440, after the fall of the Ikshvakus, the Salankayanas ruled part of the east coast from Vengi. Like the Vishnukundinas of Vinukonda who succeeded them, the Salankayanas were vassals of the Pallavas of the southern Telugu and northern Tamil lands. At this time, Telugu and Kannada scripts began to separate from those of other Indian dialects.

Pallavas The Pallava dynasty ruled South India from the fourth to the ninth centuries from Kanchipuram in Tamil Nadu. It was ascendant during the reigns of Mahendravarman I (590–630) and Narasimhavarman I (630–668) and included the southern Telugu and the north of the Tamil regions.