This study, which is based on social exchange theory (SET), focuses on the capacities of social media to provide such means by examining the effect of value in online communities (VOC) in social media platforms on satisfying ecotourists' online socialisation and knowledge sharing. Based on the data obtained from 543 ecotourists and analysed by structural equation modelling (SEM), the results of this study confirmed that VOC, which embeds the SET factors of cooperation, reputation, trust and altruism, significantly influenced ecotourists' satisfaction in socialisation and knowledge-sharing intentions through social media. Furthermore, VOC served as a higher-/second-order factor reflected by the indicators of cooperation, reputation, trust and altruism. Finally, ecotourists' satisfaction in socialisation exerted a significant mediating effect between VOC and knowledge sharing.