Injection molding is a common plastic processing technique that allows melted plastic to be injected into a mold through pressure to form differently shaped plastic parts. In injection molding, in-mold electronics (IME) can include various circuit components, such as sensors, amplifiers, and filters. These components can be injected into the mold to form a whole within the melted plastic and can therefore be very easily integrated into the molded part. The brain–computer interface (BCI) is a direct connection pathway between a human or animal brain and an external device. Through BCIs, individuals can use their own brain signals to control these components, enabling more natural and intuitive interactions. In addition, brain–computer interfaces can also be used to assist in medical treatments, such as controlling prosthetic limbs or helping paralyzed patients regain mobility. Brain–computer interfaces can be realized in two ways: invasively and noninvasively, and in this paper, we adopt a noninvasive approach. First, a helmet model is designed according to head shape, and second, a printed circuit film is made to receive EEG signals and an IME injection mold for the helmet plastic parts. In the electronic film, conductive ink is printed to connect each component. However, improper parameterization during the injection molding process can lead to node displacements and residual stress changes in the molded part, which can damage the circuits in the electronic film and affect its performance. Therefore, in this paper, the use of the BCI molding process to ensure that the node displacement reaches the optimal value is studied. Second, the multistrategy differential evolutionary algorithm is used to optimize the injection molding parameters in the process of brain–computer interface formation. The relationship between the injection molding parameters and the actual target value is investigated through Latin hypercubic sampling, and the optimized parameters are compared with the target parameters to obtain the optimal parameter combination. Under the optimal parameters, the node displacement can be optimized from 0.585 to 0.027 mm, and the optimization rate can reach 95.38%. Ultimately, by detecting whether the voltage difference between the output inputs is within the permissible range, the reliability of the brain–computer interface after node displacement optimization can be evaluated.