We study optimal effort and compensation in two continuous-time double-sided models with cost synergies. In the co-work synergy model, cost synergies exist between two agents with ongoing effort: each agent's effort reduces his colleague's marginal cost of effort. The agents completely divide the project's cash flow. In the optimal contract, the agent with higher productivity and a bigger cost-reduction influence claims a larger fraction of the cash flow. In the chain synergy model, one agent exerts initial effort to start the project, and her colleague exerts ongoing effort to manage it. The upfront effort reduces the marginal cost of her colleague's ongoing effort. The timing of optimal payments reflects cost synergies across agents and the timing of efforts: Upfront effort corresponds to early payments. We show that the introduction of cost synergies not only alters the allocation of the cash flow but also improves the expected social surplus. This study suggests that cost synergies increase efficiency for a broad set of contracting problems involving teams.