This study examines factors influencing self-efficacy in Java programming among computer science undergraduates in Nigeria, focusing on intrinsic factors like gender, computer ownership, mathematics background, and computer experience, along with institutional type. The findings indicate that mathematics background significantly predicts self-efficacy, while institutional levels account for a majority of variations. The study recommends enhancing mathematics course offerings in computer science curricula to improve programming self-efficacy.