Many real-world networks exhibit community structure: the connections within each community are dense, while connections between communities are sparser. Moreover, there is a common but non negligible phenomenon, collective behaviors, during the outbreak of epidemics, are induced by the emergence of epidemics and in turn influence the process of epidemic spread. In this paper, we explore the interaction between epidemic spread and collective behavior in scale-free networks with community structure, by constructing a mathematical model that embeds community structure, behavioral evolution and epidemic transmission. In view of the differences among individuals' responses in different communities to epidemics, we use nonidentical functions to describe the inherent dynamics of individuals. In practice, with the progress of epidemics, individual behaviors in different communities may tend to cluster synchronization, which is indicated by the analysis of our model. By using comparison principle and Geffgorin theorem, we investigate the epidemic threshold of the model. By constructing an appropriate Lyapunov function, we present the stability analysis of behavioral evolution and epidemic dynamics. Some numerical simulations are performed to illustrate and complement our theoretical results. It is expected that our work can deepen the understanding of interaction between cluster synchronization and epidemic dynamics in scale-free community networks. (C) 2018 Elsevier Ltd. All rights reserved.