Abstract: This classroom action research (CAR) presents a research for solving the student’s problems in writing class by using two cycles of Kemmis and McTaggart. In this CAR, there are three crucial instruments. They are students’ learning journal to know what the student’ map thinking which is related to the cognitive code and the writing material, researcher’ journal and questionnaire. The students' problems in writing subject happen in one class of English Department of the University of Kuningan, West Java – Indonesia. The learners find it difficult to process words into sentences. Applying cognitive code in this CAR is the strategy, with the purpose to know what the students need by asking them to use some tools such as student’s learning journal, thus the students are able to tell their difficulties based on their learning experiences in class. Cognitive code looks students or learners as thinking being and learn based on their learning experience. The students’ writing competence in the beginning of this research is 40, meanwhile, after applying cognitive code as the method of teaching learning process, the class average gets 64.5 in the post test. Thus, the normalized gain to measure the students’ writing development is on number 0.7, it means the students’ writing improvement is moderate. The students’ attitude toward cognitive code is taken from rating scales is 82%. Based on the data, it can be concluded that cognitive code is effective method in teaching writing.Keywords: cognitive code, writing competence, learners’ errors