In this paper, we discuss the existence, uniqueness and stability of solutions for a nonlocal boundary value problem of nonlinear fractional differential equations with two Caputo fractional derivatives. By applying the contraction mapping and O’Regan fixed point theorem, the existence results are obtained. We also derive the Ulam-Hyers stability of solutions. Finally, some examples are given to illustrate our results.