Lattice distortion and disorder in the chemical environment of magnetic atoms within high-entropy compounds present intriguing issues in the modulation of magnetic functional compounds. However, the complexity inherent in high-entropy disordered systems has resulted in a relative scarcity of comprehensive investigations exploring the magnetic functional mechanisms of these alloys. Herein, we investigate the magnetocaloric effect (MCE) of the high-entropy intermetallic compound Gd0.2Tb0.2Dy0.2Ho0.2Er0.2Co2. Notably, the operating temperature range of the MCE broadens by an order of magnitude from 9 to 83 K while maintaining the refrigeration capacity compared to ErCo2. Atomic-scale microstructure analysis and atomic pair distribution function measurements reveal that lattice distortion stabilizes the cubic structure and induces disorder in the chemical environment of magnetic atoms. First-principles calculations point out that the enhanced average correlation energy raises the Curie temperature. The random distribution of elements across these sites induces local magnetic disorder around magnetic atoms with lower correlation energy, broadening the operating temperature range of MCE. This study not only significantly advances the understanding of the magnetic behavior of high-entropy alloys but also promotes the research progress of high-entropy functional compounds.