The results we obtained earlier indicate the potential for corrective effects on the negative consequences of social isolation on the functioning of the body through an enriched environment. The aim of the present study was to investigate the influence of housing conditions for rats – standard conditions, social isolation, and an enriched environment – on the activity of the hypothalamic-pituitary-adrenocortical (HPA) axis, focusing on HPA axis stress reactivity, pain sensitivity, and rat behavior following exposure to an ulcerogenic stressor. The experiments were conducted on male Sprague-Dawley rats. Thirty-day-old rats, after being weaned from their mothers, were placed in different housing conditions for four weeks: standard environment (SE), isolation (SI), or an enriched environment (EE). After four weeks, rats from each group were exposed to an ulcerogenic stressor (US): 3 hours of cold immobilization (10 °C). Starting the day after US exposure, for one week, all groups of rats were sequentially assessed for somatic pain sensitivity (in the “hot plate” test), behavior (in the “open field” and “elevated plus maze” tests), and HPA stress reactivity (based on corticosterone levels in response to mild procedural stress). According to the results, SI conditions in our experimental setup led to a faster increase in body weight with age, higher anxiety levels, depressive-like reactions in half of the animals studied, and increased sensitivity to painful stimuli. At the same time, rats kept in the EE showed higher HPA axis stress reactivity, greater motor and exploratory activity, lower anxiety, and lower sensitivity to painful stimuli. The obtained results provide new evidence supporting our previous conclusion that SI exerts maladaptive effects on the overall functional state of the rats' bodies, while EE, on the contrary, leads to adaptive changes in the body. This study highlights the importance of an integrative approach when studying the effects of SI and EE on the body.