After five years of legal residency, you may apply for Portuguese citizenship. You need to be older than 18 years old and to have knowledge of the Portuguese language.
Children born in Portugal from migrant parents, if the one of the parents has been a legal resident for at least one year, are automatically Portuguese citizens.