Immigration and refugee crisis are only one of the major problems many European countries are currently facing, including the transition countries, such as Serbia. Reactions to refugees and immigrants from the Middle East and North Africa are polarized and raise the issue of moral aspects of attitudes towards them. Lately, human (im)morality has often been investigated through the concepts of the Dark Tetrad traits and Moral Foundations. The aim of this research aim is to investigate the role of the Dark Tetrad traits and Moral Foundations in the understanding of general and specific, situation-related prosocial attitudes towards immigrants. The results of the current study (N=629 respondents from Serbia) have shown that Harm/ Care and Fairness/Reciprocity (Individualizing Foundations) correlated negatively with the Dark Tetrad traits. On the other hand, Ingroup/Loyalty, Authority/Respect and Purity/Sanctity (Binding Foundations) correlated positively with these traits. The general attitude towards immigrants is mainly explained by moral foundations: the positive effect of Harm/Care and negative effects of Authority/Respect and Purity/Sanctity were detected, with the marginal negative effect of Machiavellianism. The specific attitude towards immigrants is explained both by the Dark Tetrad traits and Moral Foundations. The expected positive effect of Fairness/Reciprocity and negative effects of sadism and Purity/Sanctity were also registered. Moral Foundations mediate the relationships between the Dark Tetrad traits and both the general and specific attitudes towards immigrants. Only narcissism and sadism have direct effects on attitudes towards them. The Binding Foundations amplified, while the Individual Foundations diminished the negative effects of the Dark Tetrad traits on both the general and specific attitudes towards immigrants. These results suggest that when people perceive threats from the "others" to their inner circle, formal boundaries of morality are weakened and even most malicious personality traits are expressed.