In this paper, the shape effect of metal films on stress-induced bending of micromachined bilayer cantilever was first systematically investigated. The cantilever makes use of residual stresses in thin films to produce a bending of micro-structures by applying preloads. A finite element analysis (FEA) model was established to analyze such a deformation, with the support of experimental and theoretical results. A new founding on the post-processing temperature of the micromachined structure was reported. The post-processing temperature and residual stresses reveal close relations. While the post-processing temperature ascends, the residual stress of the metal increases, resulting in a bigger out-of-plane deformation of the cantilever. The residual stress rises to a saturated value while the temperature reaches a critical value. Finally, a switchable micromachined corner mirror and a high-speed low-voltage double-switch electrostatically actuated optical crossconnect (OXC) were demonstrated using stress-induced cantilevers.