Casing is the physical barrier of oil and gas well, and its integrity is the key to realize wellbore integrity. Cement sheath is one of the most important barriers to ensure the integrity of casing. There are many studies on the influence of mechanical parameters of cement sheath on the mechanical behavior of casing, but most studies ignore the close relationship between the casing force and the elastic modulus of the cement sheath and formation. Therefore, a two-dimensional finite element model of casing-cement sheath-formation is established; the influence of sensitive factors on the mechanical behavior of casing under the elastic modulus different matching relationships of cement sheath and formation was analyzed. The adaptability analysis of the elastic modulus of the two was carried out to optimize the range of elastic modulus of cement sheath. The results show that the elastic modulus different matching relationships between cement sheath and formation may lead to a 90° transformation of the maximum stress distribution of casing, resulting in a great difference in the location of casing damage in the same geological blocks. Moreover, the matching relationship between the two affects the influence of sensitive factors such as casing wall thickness, wellbore ellipticity and casing eccentricity on casing stress. Therefore, it is necessary to optimize the range of cement sheath elastic modulus according to the elastic modulus of formation and working conditions. The research results are of great significance for the study of casing failure mechanism and the selection of elastic modulus of cement sheath.