The paper deals with the effect of modernization (electronicization, automatiztion and prospective use of artificial intelligence) of public administration on guarantees of compliance with the principles of the rule of law in the realization of administrative activities. It mentions some legal aspects of the modernization of public administration in the Czech Republic and the preparation of a European legal act on artificial intelligence.