He studied law at the University of Coimbra. Noted for his political activities, he spent a decade in exile in Algeria during the Estado Novo era, returning days after the 1974 Revolution. He served as a member of Parliament and also ran as a candidate for the Portuguese presidential election in 2006. Several of his poems have been made into songs by musicians such as Zeca Afonso (1929-1987). Alegre is the recipient of the 2017 Camões Prize for his poetry and prose work.