We examined the associations of middle childhood and adolescence nighttime sleep duration with adolescence internalizing and externalizing behavior problems per the Youth Self-Report (YSR) and the Child Behavior Checklist (CBCL) questionnaires, in a cohort of 889 Colombian schoolchildren. We estimated adjusted differences with 95% confidence intervals (CI) in mean behavior problem t-scores in standardized units between recommended sleep duration categories and as a continuous exposure using multiple linear regression and restricted cubic spline models, respectively. Compared with sleep duration within recommendations, middle childhood sleep above recommendations was related to 4.6 (95% CI: 1.6, 7.6; p = .004) and 5.4 (95% CI: 1.2, 9.7; p = .01) adjusted units higher YSR and CBCL externalizing problem scores, respectively. In continuous exposure analyses, this association seemed restricted to children aged ≥11 years. Longer sleep, both in categories and as a continuous exposure, was also associated with increased CBCL internalizing problems. Results did not differ by sex or weekend/weekday sleep. Sleeping under recommendations in middle childhood was not significantly related to behavior problems; nevertheless, shorter sleep in adolescence, in both categorical and continuous scales, was significantly related to behavior problems. In conclusion, behavior problems in adolescence are associated with longer sleep in middle childhood and shorter sleep in adolescence.