Abstract: This study investigates the identification and estimation of causal effects when individuals interact with each other. In this context, an individual’s potential outcome is influenced by the treatment statuses of all individuals. Specifically, the treatment of others affects outcomes through ``exposures,” such as the number of treated friends, which generally depend on the underlying network structure. When the network is also impacted by the treatment, an individual’s treatment affects the outcome both directly and indirectly—by altering the distribution of exposures. Since the exposure mediates the effect of the treatment on the outcome, it can be considered a mediator. This study decomposes these direct and indirect effects by applying a causal mediation analysis framework. The required observable variables are outcomes, treatment statuses, and exposures for each individual. The variation in exposures based on different treatment statuses is essential to identify these components separately. A simple nonparametric estimation procedure is proposed, and its performance is assessed using Monte Carlo simulations. This approach is then applied to an empirical setting to examine the impact of attending coeducational high schools on academic performance.