The ability to recursively infer the mental states of others to explain their complex behavior in ambiguous social situation may be called Advanced Theory of Mind (aToM). The relations between two components of aToM, cognitive and affective, measured on a behavioral level in 151 Polish 13-year-olds and 174 16-year-olds was examined. The role of age, gender and friendship style and its relations to the cognitive and affective aToM was explored. Cognitive aToM was only weakly to moderately related to affective aToM. Across both age groups females scored higher than males. Males' aToM abilities did not differ according to age, but they scored higher in the cognitive aToM than affective ToM. Also, different aspects of friendship style were significant predictors of both aToM abilities. The implications for two aToM components within a gendered social context were discussed. (C) 2017 The Foundation for Professionals in Services for Adolescents. Published by Elsevier Ltd. All rights reserved.