The present study was designed to observe the effect of COX2/PGD2-related autophagy on brain injury in type 2 diabetes rats. The histopathology was detected by haematoxylin–eosin staining. The learning and memory functions were evaluated by Morris water maze. The levels of insulin and PGD2 were measured by enzyme-linked immunosorbent assay. The expressions of COX2, p-AKT(S473), p-AMPK(T172), Aβ, Beclin1, LC3BII, and p62 were measured by immunohistochemistry and Western blotting. In model rats, we found that the body weight was significantly decreased, the blood glucose levels were significantly increased, the plasma insulin content was significantly decreased, the learning and memory functions were impaired and the cortex and hippocampus neurons showed significant nuclear pyknosis. The levels of COX2, p-AKT(S473), PGD2, Aβ, Beclin1 and p62 were significantly increased, whereas the expression of p-AMPK(T172) and LC3BII was significantly decreased in the cortex and hippocampus of model rats. In meloxicam-treated rats, the body weight, blood glucose and the content of plasma insulin did not significantly change, the learning and memory functions were improved and nuclear pyknosis was improved in the cortex and hippocampus neurons. The expression of p-AMPK(T172), Beclin1 and LC3BII was significantly increased, and the levels of COX2, p-AKT(S473), PGD2, Aβ, and p62 were significantly decreased in the cortex and hippocampus of meloxicam-treated rats. Our results suggested that the inhibition of COX2/PGD2-related autophagy was involved in the mechanism of brain injury caused by type 2 diabetes in rats.