This paper presents the experiment-based mathematical modelling of fluidized bed carbonitriding process for 1C 25 steel meant to optimize this type of thermochemical processing.Based on experimental results, the mathematical model was developed, which is a second order equation with three unknown terms (parameters): temperature, depth of carbonitrided layer, the percentage of ammonia.The mathematical model allowed the simulation of the fluidized layer carbonitriding process according to its parameters and the thermal energy optimization for obtaining HV hardness values in the range 300-400 MPa.Using the software package Matlab a graphical interface was done, through which all the combinations of technological parameters of the carbonitriding process are determined, leading to obtaining values of microhardness between 300 and 400 MPa, as well as the amount of energy consumed for each variant. The variant consuming the lowest energy is considered optimal.