BackgroundEncouraging professional integrity is vital for providing a standard of excellence in quality medical care and education and in promoting a culture of respect and responsibility. The primary objective of this work consisted of studying the relationship of medical students to the right to patient privacy in Spain, specifically by analysing the conditions for accessing patient clinical histories (CHs).MethodsA cross-sectional study was conducted based on a questionnaire sent by e-mail to final-year students at 41 Spanish universities. It had 14 multiple choice and closed questions framed in 3 large blocks. The first question addressed basic general knowledge issues on the right to privacy and the obligation for confidentiality. The two remaining blocks were made up of questions directed towards evaluating the frequency with which certain requirements and action steps related to students attending patients were performed and regarding the guarantees associated with accessing and handling patient CHs both on paper and in the Electronic Medical Record.ResultsA total of 245 valid replies were considered. A total of 67.8 % of participants were women, with an average age of 24.05 ± 3.49 years. Up to 90.6 % were aware that confidentiality affected the data in CHs, although 43.3 % possessed non-anonymized photocopies of patient clinical reports outside the healthcare context, and only 49.8 % of the students were always adequately identified. A total of 59.2 % accessed patient CHs on some occasions by using passwords belonging to healthcare professionals, 77.2 % of them did not have the patients’ express consent, and 71.9 % accessed a CH that was not anonymised.ConclusionsThe role of healthcare institutions and universities is considered to be fundamental in implementing educational measures regarding the risks and ethical and legal problems arising from the use of CHs among professionals and students. A thorough study of medical ethics is needed through the analysis of clinical cases and direct exposure to situations in which the patient’s confidentiality is questioned.