Software cost estimation (SCE), estimating the cost and time required for software development, plays a highly significant role in managing software projects. A somewhat accurate SCE is necessary for a software project to be successful. It allows effective control of construction time and cost. In the past few decades, various models have been presented to evaluate software projects, including mathematical models and machine learning algorithms. In this paper, a new model based on the hybrid of the artificial fish swarm algorithm (AFSA) and the artificial bee colony (ABC) algorithm is presented for SCE. The initial population of AFSA, which includes the values of the effort factors, is generated using the ABC algorithm. ABC algorithm is used to solve the problems of the AFSA algorithm such as population diversity and getting stuck in a local optimum. ABC algorithm achieves the best solutions using observer and scout bees. The evaluation of the combined method has been implemented on eight different data sets and evaluated based on eight different criteria such as mean magnitude of relative error and PRED (0.25). The proposed method is more error-free than current SCE methods, according to the results. The error value of the proposed method is lower on NASA60, NASA63, and NASA93 datasets.