Bile duct ligation (BDL) induces primary biliary cirrhosis characterized by cholestasis, impaired liver function, and cognition. Young male Sprague-Dawley rats were used: rats underwent laparotomy without BDL ͓sham-control (SC) group͔; rats had restricted diets supply ͓diet-control (DC) group͔; rats underwent BDL for 2 wk (BDL group); BDL rats with melatonin (500 g/kg/d) intraperitoneally for 2 wk ͓melatonin (500 g/kg/d) (M500) group͔; and BDL rats with melatonin (1000 g/kg/d/intraperitoneally) for 2 wk ͓melatonin (1000 g/kg/d) (M1000) group͔. All the surviving rats were assessed for spatial memory and blood was tested for biochemical study. Liver, brain cortex, and hippocampus were collected for determination of malondialdehyde (MDA) and glutathione (GSH)/ oxidized glutathione (GSSG) ratios. BDL group rats had significantly higher plasma direct/total bilirubin, aspartate aminotransferase (AST), alanine aminotransferase (ALT), MDA values and higher liver MDA values and lower GSH/GSSG ratios when compared with SC group. In addition, BDL group rats had impaired spatial performance. After melatonin treatment, cholestatic rats' plasma MDA levels, liver MDA levels, and liver GSH/GSSG ratios approached to the values of SC group. Only high dose of melatonin improved spatial performance. Results of this study indicate cholestasis in the developing rats increase oxidative stress and cause spatial memory deficits, which are prevented by melatonin treatment.