Objective: Vitamin D is needed for the proper functioning of the immune system.Sunlight exposure is essential for the synthesis of Vitamin D.Covid-19 pandemic and the subsequent lockdowns have resulted in reduced outdoor activities in the student community because of online education. This could lead to the deficiency of Vitamin D.We undertook this study to assess the knowledge, attitude, and awareness of sunlight exposure and Vitamin D among the medical and dental students during the lockdown period. Methods This study was conducted as a pre-validated voluntary crosssectional observational online survey,using the Google form in 347 medical and dental undergraduates after obtaining the approval from Institutional Ethical Committee. The questionnaire was aimed to assess the level of knowledge and practices about sunlight exposure, sunscreen usage and Vitamin D of the participants. Data was analysed statistically using Kruskal–Wallis and Chi square tests. Results Among 347 respondents, 46% of dental and 57.3% of the medical students preferred to go out in the sun. This was statistically significant (p<0.05). There was a statistically significant difference between the groups in the questions pertaining to sources of Vitamin D. Conclusion This is a preliminary exploratory survey pertaining to the knowledge and practices about sun exposure and Vitamin D during the pandemic period.Even though majority of our participants were aware of the significance of Vitamin D and sunlight for bone health, it is emphasized that they consume Vitamin D fortified foods, expose themselves to direct sunlight which in turn will strengthen their immunity.