This study aims to develop an integrated computational framework for the reliability-based design optimization (RBDO) of wind turbine drivetrains to assure the target reliability under wind load and gear manufacturing uncertainties. Gears in wind turbine drivetrains are subjected to severe cyclic loading due to highly variable wind loads that are stochastic in nature. Thus, the failure rate of drivetrain systems is reported to be higher than the other wind turbine components, and improving drivetrain reliability is critically important in reducing downtime caused by gear failures. In the numerical procedure developed in this study, a wide spatiotemporal variability for wind loads is considered using 249 sets of wind data to evaluate probabilistic contact fatigue life in the sampling-based RBDO. To account for wind load uncertainty in evaluation of the tooth contact fatigue, multiple drivetrain dynamics simulations need to be run under various wind load scenarios in the RBDO process. For this reason, a numerical procedure based on the multivariable tabular contact search algorithm is applied to the modeling of wind turbine drivetrains to reduce the overall computational time while retaining the precise contact geometry required for considering the gear tooth profile optimization. An integrated computational framework for the wind turbine drivetrain RBDO is then developed by incorporating the wind load uncertainty, the rotor blade aerodynamics model, the drivetrain dynamics model, and the probabilistic contact fatigue failure model. It is demonstrated that the RBDO optimum for a 750 kW wind turbine drivetrain obtained using the procedure developed in this study can achieve the target 97.725% reliability (2 sigma quality level) with only a 1.4% increase in the total weight from the baseline design, which had a reliability of 8.3%. Furthermore, it is shown that the tooth profile optimization, tip relief introduced as a design variable, prevents a large increase of the face width that would result in a large increase in the weight (cost) of the drivetrain in order to satisfy the target reliability against the tooth contact fatigue failure.