This study analyzes the impact of transfer pricing on multinational enterprises' R&D investment decisions. Specifically, I examine the effects of two commonly used contract designs to exchange and develop intangible assets across group affiliates: licensing and cost sharing agreements. Whilst serving as a tool to allocate taxable income between group affiliates, the economic implications of licensing and cost sharing agreements differ. Whereas licensing agreements provide for a sharing rule on the intangible's profits, cost sharing agreements on the other hand provide a sharing rule on R&D development costs. This difference matters when firms simultaneously use internal transfer prices to allocate taxable income and provide local management with sufficient investment incentives. Using a multiple-agent, moral hazard investment framework I model a multinational firm with comparable group affiliates in two countries that delegates the R&D investment decision to a local risk and effort averse affiliate manager. The results suggest that the optimal contract not only depends on available tax benefits, but also on R&D investment and manager specific characteristics. A licensing agreement provides management with larger incentives to invest in R&D mitigating agency concerns associated with R&D. On the other hand, using a cost sharing agreement the firm can cater different risk preferences among managers potentially increasing investment. The arm's length principle however may distort an efficient allocation of R&D costs when using a cost sharing agreement.