With the continuous deepening of research and development in the field of aerospace, the requirements for aerospace payloads are also increasing. The stray light received by the spaceborne telescope in the space environment will be one of the most important factors affecting its performance. The optical mechanical surface of spaceborne telescope will deviate from the original design due to various objective factors during the whole link process, and the actual optical mechanical surface is not ideal. In order to ensure that it can work normally, it is necessary to simulate and analyze the stray light situation of the whole link. This paper mainly introduces the complex environment and complex characteristics experienced from the ground section to the orbit section, analyzes and summarizes the sources of stray light, and finally proposes a framework for establishing a digital twin model of stray light for spaceborne telescopes. Through data-driven and model-driven methods, finally build a complete set of ground, launch, and in-orbit digital twin models.