The dynamic characteristics of the milling process system respond to the variation tool clamping length, which affect the related milling stability and machined surface quality. In further, they lead to the uncertainty of milling process planning. To address this issue, the tool overhang length and traditional milling parameters are combined as the inputs. Then, two back propagation neural networks (BPNNs) are introduced to predict the limiting axial cutting depth and the surface roughness, respectively. Furthermore, two BPNNs are used to express the constraints of milling stability and machining quality. Then, an optimization model is formulated to decrease the total cutting time of the rough and finish milling processes, where the tool overhang length and the milling parameters for rough and finish processes are designed as the optimization variables. The sparrow search algorithm is used to solve the optimization model. A case study is implemented on a CNC machine tool to milling the fixture cavity. The optimal configuration of tool overhang length and milling parameters are achieved. The total cutting time is 12. 577 min and the measured surface roughness is 3. 01 μm, which verify the feasibility and effectiveness of the proposed optimization model.