Cosmetics and beauty products rank third as the group of goods with the most sales through e-commerce transactions in 2020. E-Commerce offers various cosmetics products and provides wider opportunities for consumers to choose local and foreign products. Ethnocentrism refers to consumers' preference for local products. This study aimed to analyze the effect of socio-psychological factors on consumer ethnocentrism and the effect of consumer ethnocentrism on purchase intention in local cosmetics through online shopping. The number of samples in this study was 210 respondents, selected using the voluntary sampling method. Data collection was obtained through an online questionnaire on Google Forms. Data analysis was carried out using the SEM-LISREL analysis tool. The results showed that socio-psychological factors, including cultural openness, patriotism, conservatism, and collectivism, significantly affected consumer ethnocentrism. Other results also showed that consumer ethnocentrism significantly affected purchase intention in local cosmetics.