The suspect allegedly arrived in Syria in October 2013 and was a member of the group until he returned home in November, German federal prosecutors said in a statement yesterday.
He is to go before a judge today, but has not been accused of involvement in any attacks and prosecutors stressed there was no link with this week's bloody assault on the Charlie Hebdo magazine offices in France.
Authorities said they had searched the man's home in Dinslaken in northwestern Germany but didn't elaborate.