NAYPYIDAW, Myanmar — Myanmar’s new president called for patience in the pursuit of full democracy after his inauguration on Wednesday ended more than half a century of rule by the military and its allies.

“We have to work for a Constitution that is in harmony with democratic values,” the new chief of state, U Htin Kyaw, said in a speech. “This is a political ambition that people have wanted for a long, long time. We have to be patient.”

Mr. Htin Kyaw is a close ally of Daw Aung San Suu Kyi, who led their party, the National League for Democracy, to a landmark victory in elections in November. She is barred from serving as president by the military-drafted Constitution, but the party has pushed to allow her to take the top post.

Image President Htin Kyaw of Myanmar, left, receiving the presidential sash from his predecessor, U Thein Sein, on Wednesday in Naypyidaw. Credit... Pool photo by Ye Aung Thu

Ms. Aung San Suu Kyi was also sworn in on Wednesday as a minister in the new government. She will lead four ministries: education, energy, foreign affairs and the presidential office.