His first job was teaching in a Victorian school. He later was an education officer in Pentridge Prison, Melbourne. In 1967 Ayers moved to Canberra as Director of Welfare in the Department of the Interior.
He was appointed to his first Secretary role in 1979 as head of the Department of Aboriginal Affairs.
Ayers moved soon after, in 1981, to the Department of Social Security (Decision Support System). During his time at Decision Support System he served concurrently for three months as Acting Secretary of the Department of Community Services.
Ayers moved to an appointment as Secretary of the Department of Community Services and Health when the Hawke Government restructured the public service and created "super ministries" in 1987. Ayers final posting in the Australian Public Service was as Secretary of the Department of Defence between 1988 and 1998.
Ayers was praised for his work in the Department, one of the few departmental heads who has left the Department of Defence on their own accord, rather than being compelled to leave by the Defence Minister, in the last 30 years.