Background Irritant contact dermatitis is the most common type of hand eczema. Effective treatment usually involves avoidance of irritants and use of appropriate topical medication. In this study, the effectiveness of using text messaging addressing preventive behaviours and appropriate medication adherence was evaluated. Methods Patients who were admitted to Istanbul Training and Research Hospital Dermatology Department March 1, 2015 to July 31, 2015, and diagnosed with hand eczema were enrolled. Patients were randomly divided into the SMS group and the non-SMS group. Text messages were sent to the mobile phones of the patients in the SMS group. Severity of hand eczema, compliance to treatment, patients' information level, adherence to preventive behaviours, and the protective behaviour score were evaluated at baseline, and at the 4th and 8th week. Results Eighty-one patients with hand eczema were included in the study. After 8 weeks, the decrease in the Hand Eczema Severity Index score was 70.2% (SD 35.2) in the SMS group and 38.9% (SD 67.7) in the non-SMS group (P = .017). Sending SMS to patients increased the use of moisturizer. There was no statistically significant difference in other behaviours. Conclusion This study demonstrated that text messaging improves the treatment success and specifically the frequency of moisturizer use in patients with hand eczema.