This paper applies a Human Error Identification tool called Technique for the Retrospective and Predictive Analysis of Cognitive Errors to the analysis of ship accidents. Grounding and collision accidents investigation reports involving sixty-four vessels published by the UK’s Maritime Accident Investigation Branch, the Transportation Safety Board of Canada and the National Transportation Safety board of the United States of America are coded and analysed using the taxonomy of the Technique for the Retrospective and Predictive Analysis of Cognitive Errors. A total of two hundred and eighty-nine errors performed by the operators are coded. The results of the codification process are analysed with the objective of identifying the main task errors, cognitive domains and the technical equipment involved in grounding and collision accidents and the factors that affect the performance of the operators. This identification is a necessary step towards safety improvements resulting from dealing with the identified problems. A discussion on the use of the taxonomy of the Technique for the Retrospective and Predictive Analysis of Cognitive Errors is provided and it is proposed to combine it with some elements of the CASMET approach to accident investigation so as to improve the applicability of the methodology to the analysis of ship accidents.