The Middle Ages were a period of rapid development of education and science in the Muslim world, including among the Turkic peoples. Along with the spread of religious teachings in the political and social spheres, many scientific ideas were born, including the art of governing the country. The article cites verses from the Qur'an and hadith concerning the government of the country and left an indelible mark on the Islamic era. Epos of Balasaguni «Kutty Bilik», epos of A. Yugneki «Hibat-ul Hakаik», the book of King Kaikawis «Qabusnama», philosophical treatises of al-Farabi, «Divani Hikmet» by Khoja Ahmed Yassawi and others. «Kutty Bilik» – a book of wisdom from the common people to the king, in which you can learn the subtleties of humanity, education, the art of governing the country, the way to the prosperity of the state. Herebouts the khan and his vizier, the palace leaders, the generals, the ambassadors, to the extent that they should be directly involved in the government of the country, correlate their behavior, intelligence, and knowledge. The poet sings of morality, humanity, spirituality. Comprehensively focuses on everything that is needed to achieve happiness. Whatever sphere of social society we take, the centuries-old activity of religion in regulating relations between people manifests itself. These relations, as well as the models of governance of the country that we are talking about, we consider it right to base on the principles of Islam, our thinkers believe.Into his works, they analyze the issues of governing the country and issues of intelligence and education that are directly related to this. Although many centuries have passed, the teachings of our ancestors, which have retained their value, are considered an inalienable legacy, and their significance today is discussed in different ways.