pic 1

Exploring the use of social media data and artificial intelligence to analyse perceptions of refugees


This project investigated the potential of using artificial intelligence and machine learning to monitor in real-time the perceptions of Europeans of migrants and refugees in Europe with Twitter data. To explore the sentiments of host communities, UNHCR and UN Global Pulse developed a set of taxonomies and algorithms to automatically detect Twitter tweets that display intense dislike or hatred against people that are perceived as outsiders, strangers, or foreigners. The team read, compiled, categorised, anonymised, and aggregated different types of posts in multiple languages to quantify both xenophobic and integration-friendly comments towards asylum seekers and refugees.


The project team conducted a series of ten quantitative mini studies in two iterations to inform the feasibility of this approach. While the results of the second iteration provide some interesting insights into the way people perceive refugees and asylum seekers, the project team remarks that they should be considered cautiously, as social media alone cannot provide a comprehensive overview of opinions. For example, tweets are generally not representative of the socio-economic diversity and age of the larger population. Furthermore, the pilot showed that the AI-based classification of either xenophobic or integration-friendly comments was not always accurate; contextual references of tweets using irony and sarcasm were not understood well; and the algorithms did not make a systematic distinction between geographic host communities and the entire national public. Going forward, the project intends to continue exploring this approach as a way to detect signals following events relevant for refugee movements – such as natural disasters or political clashes – which UNHCR may need to act upon.


(Picture: © UNHCR, Achilleas Zavallis)

Last modified
27 May 2021