The moral crisis and low religious understanding among the younger generation pose serious challenges in shaping students' character in accordance with Islamic teachings. This phenomenon is increasingly exacerbated by the rapid flow of globalization and technological developments that are not always in line with the principles of Islamic law. In this context, the existence of Madrasah Diniyah (Islamic Madrasah) is a strategic solution to equip students with a deep understanding of religion while simultaneously forming a strong Islamic personality (syakhsiyah Islamiyyah). This study aims to determine the role of Madrasah Diniyah in improving mastery of Islamic religious knowledge and shaping Islamic character in students. The study used a descriptive qualitative approach with the aim of systematically describing the learning process and its impact on student development. Data were collected through observation, in-depth interviews with teachers and students, and analysis of learning documents. The results show that Madrasah Diniyah plays a significant role in improving mastery of Islamic religious knowledge through structured learning that includes the Qur'an, aqidah, fiqh, and morals. This material not only broadens students' religious knowledge but also instills the values of faith, worship, and noble morals that serve as the foundation for daily behavior. This success is supported by teachers who possess strong scientific and pedagogical competence, varied learning methods, and harmonious relationships between teachers, students, and parents. Furthermore, a conducive madrasah environment helps strengthen the internalization of Islamic values. Thus, Madrasah Diniyah serves as a vital partner in the Islamic education system, particularly in instilling an Islamic personality from an early age, thus fortifying the younger generation against the negative influences of globalization and shaping a generation of faith, knowledge, and noble morals.