Cordycepin is a bioactive compound with extensive pharmacological activities and potential medical applications. This study focuses on the optimization of cordycepin production in an engineered Pichia pastoris strain, THP-292, constructed in our laboratory. By screening optimal culture media and supplementing with adenine and fucoidan, we aimed to improve cordycepin synthesis and enhance stress tolerance. The results showed that the BSM medium supported better growth and higher cordycepin production compared to other media, while offering simpler composition and easier downstream processing. The addition of fucoidan significantly increased cell viability during the later fermentation stages, improving stress resistance. Meanwhile, adenine supplementation doubled the cordycepin yield. This provides new insights into enhancing cordycepin synthesis in P. pastoris and understanding cellular adaptations to various environmental conditions.