From Wikipedia:
Although Portuguese and Spanish are closely related, to the point of having a considerable degree of mutual intelligibility, there are also important differences between them, which can pose difficulties for people acquainted with one of the languages who attempt to learn the other. Both are part of a broader group known as West Iberian Romance, which also contains several minor languages or dialects with fewer speakers, all of which are mutually intelligible among themselves to some degree.
There are also some significant differences between Brazilian Portuguese and European Portuguese as there are between British and American English or Spanish in Spain and Spanish in Puerto Rico. This article notes these differences below only where:
* both Brazilian and European Portuguese differ not only from each other, but from Spanish as well;
* both European and Latin American Spanish differ not only from each other, but also from Portuguese; or
* either Brazilian or European Portuguese differs from Spanish with syntax not possible in Spanish (while the other dialect does not)