Foeniculum vulgare Mill. (commonly known as fennel) is used in the pharmaceutical, cosmetic, and food industries. Fennel widely used as a digestive, carminative, galactagogue and diuretic and in treating gastrointestinal and respiratory disorders. Improving low heritability traits such as essential oil yield (EOY%) and trans-anethole yield (TAY%) of fennel by direct selection does not result in rapid gains of EOY% and TAY%. Identification of high-heritable traits and using efficient modeling methods can be a beneficial approach to overcome this limitation and help breeders select the most advantageous traits in medicinal plant breeding programs. The present study aims to compare the performance of the artificial neural network (ANN) and multilinear regression (MLR) to predict the EOY% and TAY% of fennel populations. Stepwise regression (SWR) was used to assess the effect of various input variables. Based on SWR, nine traits—number of days to 50% flowering (NDF50%), number of days to maturity (NDM), final plant height (FPH), number of internodes (NI), number of umbels (NU), seed yield per square meter (SY/m2), number of seeds per plant (NS/P), number of seeds per umbel (NS/U) and 1000-seed weight (TSW)—were chosen as input variables. The network with Sigmoid Axon transfer function and two hidden layers was selected as the final ANN model for the prediction of EOY%, and the TanhAxon function with one hidden layer was used for the prediction of TAY%. The results revealed that the ANN method could predict the EOY% and TAY% with more accuracy and efficiency (R2 of EOY% = 0.929, R2 of TAY% = 0.777, RMSE of EOY% = 0.544, RMSE of TAY% = 0.264, MAE of EOY% = 0.385 and MAE of TAY% = 0.352) compared with the MLR model (R2 of EOY% = 0.553, R2 of TAY% = 0.467, RMSE of EOY% = 0.819, RMSE of TAY% = 0.448, MAE of EOY% = 0.624 and MAE of TAY% = 0.452). Based on the sensitivity analysis, SY/m2, NDF50% and NS/P were the most important traits to predict EOY% as well as SY/m2, NS/U and NDM to predict of TAY%. The results demonstrate the potential of ANNs as a promising tool to predict the EOY% and TAY% of fennel, and they can be used in future fennel breeding programs.