A method for estimating SOC of a lithium battery, comprising steps of: collecting state data and corresponding SOC values of lithium batteries under different working conditions and establishing a sample set, and performing clustering analysis on the sample set to obtain a plurality of sample subsets; establishing a corresponding sub-model for each of the sample subsets by performing linear regression operation to obtain sub-model functions of the plurality of sample subsets; characterized by adding the state data of a sample to be tested respectively into the state data of each of the sample subsets, calculating a change value of the state data of each of the sample subsets before and after the adding operation, and selecting at least one sub-model close to the sample to be tested as the selected sub-model according to the change value; assigning a weight to the selected sub-model, and calculating the SOC value of the sample to be tested; the step of assigning a weight to the selected sub-model comprises: making the weight of each selected sub-model in the selected sub-models be P ( X s | x test),, s=q1, q2,..., qNc; the expression formula of the weight is as follows: P X s x test = P X s P x test X s ∑ s = q 1 q N c P X s P x test X s wherein P x test X s = K s ′ ∑ s = q 1 q N c K s ′ P X s = 1 N c. wherein P(X s) is the prior probability that X s can describe the current working condition of the lithium battery, P ( x test | X s) represents the probability that x test may be generated by X s; the step of calculating the SOC value of the sample to be tested is to calculate the SOC value through the following formula: y ^ test = ∑ s = q 1 q N c P X s x test f s x test = ∑ s = q 1 q N c K s ′ f s x test ∑ s = q 1 q N c K s ′ wherein y test is the estimated value of SOC, x test is the state data of a sample to be tested, q 1 is the selected 1 st sub-model, q Nc is the selected Nc st P(X s |x test) sub-model, s is the selected s st sub-model, is the weight of the selected s st sub-model, f s (x test) is the sub-model function of the selected s st sub-model, K S ′ is the divergence information value. collecting state data and corresponding SOC values of lithium batteries under different working conditions and establishing a sample set, and performing clustering analysis on the sample set to obtain a plurality of sample subsets; establishing a corresponding sub-model for each of the sample subsets by performing linear regression operation to obtain sub-model functions of the plurality of sample subsets; characterized by adding the state data of a sample to be tested respectively into the state data of each of the sample subsets, calculating a change value of the state data of each of the sample subsets before and after the adding operation, and selecting at least one sub-model close to the sample to be tested as the selected sub-model according to the change value; assigning a weight to the selected sub-model, and calculating the SOC value of the sample to be tested; the step of assigning a weight to the selected sub-model comprises: making the weight of each selected sub-model in the selected sub-models be P ( X s | x test),, s=q1, q2,..., qNc; the expression formula of the weight is as follows: P X s x test = P X s P x test X s ∑ s = q 1 q N c P X s P x test X s wherein P x test X s = K s ′ ∑ s = q 1 q N c K s ′ P X s = 1 N c. wherein P(X s) is the prior probability that X s can describe the current working condition of the lithium battery, P ( x test | X s) represents the probability that x test may be generated by X s; the step of calculating the SOC value of the sample to be tested is to calculate the SOC value through the following formula: y ^ test = ∑ s = q 1 q N c P X s x test f s x test = ∑ s = q 1 q N c K s ′ f s x test ∑ s = q 1 q N c K s ′ wherein y test is the estimated value of SOC, x test is the state data of a sample to be tested, q 1 is the selected 1 st sub-model, q Nc is the selected Nc st P(X s |x test) sub-model, s is the selected s st sub-model, is the weight of the selected s st sub-model, f s (x test) is the sub-model function of the selected s st sub-model, K S ′ is the divergence information value. making the weight of each selected sub-model in the selected sub-models be P ( X s | x test),, s=q1, q2,..., qNc; the expression formula of the weight is as follows: P X s x test = P X s P x test X s ∑ s = q 1 q N c P X s P x test X s wherein P x test X s = K s ′ ∑ s = q 1 q N c K s ′ P X s = 1 N c. wherein P(X s) is the prior probability that X s can describe the current working condition of the lithium battery, P ( x test | X s) represents the probability that x test may be generated by X s; the step of calculating the SOC value of the sample to be tested is to calculate the SOC value through the following formula: y ^ test = ∑ s = q 1 q N c P X s x test f s x test = ∑ s = q 1 q N c K s ′ f s x test ∑ s = q 1 q N c K s ′ wherein y test is the estimated value of SOC, x test is the state data of a sample to be tested, q 1 is the selected 1 st sub-model, q Nc is the selected Nc st P(X s |x test) sub-model, s is the selected s st sub-model, is the weight of the selected s st sub-model, f s (x test) is the sub-model function of the selected s st sub-model, K S ′ is the divergence information value.