In 1977, Spain had its first free elections in 41 years. Suárez was elected Prime Minister. He and the people working with him won the 1979 elections under the new constitution. He resigned as Prime Minister on 29 January 1981.