Spanish police say they have arrested a man at Madrid's Barajas airport who was attempting to join the Islamic State extremist group in war-torn Syria.

Spain's Interior Ministry says in a statement that the suspect is a Spanish citizen of Palestinian origin who lives on Gran Canaria in the Canary Islands archipelago.

The suspect has been under police surveillance since 2014 when police detected that he was "in the process of jihadist radicalization" after having "consumed propaganda from the (IS) terrorist group which had led him to be willing to travel and join their ranks."

Spanish police have arrested 164 individuals suspected of forming part of Islamic extremist groups since 2015.