Abstract Road cracks pose a serious threat to the stability of road structures and traffic safety. Therefore, this paper proposes an optimized accurate road crack segmentation network called MBGBNet, which can solve the problems of complex background, tiny cracks, and irregular edges in road segmentation. First, multi‐scale domain feature aggregation is proposed to address the interference of complex background. Second, bidirectional embedding fusion adaptive attention is proposed to capture the features of tiny cracks, and finally, Gaussian weighted edge segmentation algorithm is proposed to ensure the accuracy of crack edge segmentation. In addition, this paper uses the preheated bat optimization algorithm, which can quickly determine the optimal learning rate to converge the equilibrium. In the validation experiments on the self‐built dataset, mean intersection over union reaches 80.54% and precision of 86.38%. MBGBNet outperforms the other seven state‐of‐the‐art crack segmentation networks on the three classical crack datasets, highlighting its advanced segmentation capabilities. Therefore, MBGBNet is an effective auxiliary method for solving road safety problems.