Abstract Background Given that the transgender and non-binary community now accounts for as much as 1.2% of the total population, they are becoming an increasingly visible subgroup of patients in the healthcare system. At the same time, research indicates that these patients often experience poorer treatment outcomes or have limited access to services. Discrepancies between medical education and subsequent patient care are addressed by incorporating comprehensive education into medical training. To the best of our knowledge, this is one of the first studies exploring healthcare students’ needs regarding transgender healthcare content in medical education in Poland. The aim of the study is to investigate healthcare students’ knowledge of and attitudes towards transgender and non-binary (TGNB) patients, their preparedness to provide healthcare for this population, and their perceived educational needs in this area. Methods An online survey on educational needs in healthcare of TGNB people was disseminated through social media and posters with a QR code. The survey was anonymous and targeted healthcare students from Poland. For open-ended questions, an inductive thematic analysis was performed. Results Two hundred and sixty-four students, from medical-related faculties, completed the questionnaire. Two hundred and thirty-two (87.9%) respondents admitted that they had not received any content on healthcare for TGNB patients during their studies to date. One hundred and sixty-one (61.0%) of the respondents believed that content on TGNB patient care should be included in the curriculum. Communication with patients (73.9%) was indicated as the most relevant issues in the care of TGNB patients. Respondents rated their knowledge and skills as lowest in surgical treatment (59.1%) and hormonal treatment (50.0%). One hundred and twenty students (45.5%) did not feel prepared to interact with TGNB patients. Conclusions Polish healthcare students express an interest in improving their knowledge and skills on the healthcare of TGNB patients. Implementing educational interventions is essential to reduce future gap in medical services access for these patients. Trial registration The decision number of the Bioethical Committee of the Medical University of Lublin is KE/138/02/24, Date of determination February 29, 2024.