We use Code V to design a small optical lens in this study. We analyze the stray light of this lens by LightTools. Stray light will affect the quality of the optical system. Stray light is divided into three types. First is stray light rays resulting in the clear aperture. Second is stray light caused by out of the clear aperture. Third is stray light caused by the mechanical structure. We use the coating and change mechanical structure and other methods to reduce stray light.