The paper presents the results of calculating the crystallization energy and examines its influence on the size of the nanostructured grain during ion-plasma treatment of aluminum (VD17) with oxygen and nitrogen ions. To address this task, we employ a previously proposed model, which considers the impact of individual ions on thermal conductivity and thermoelasticity in the affected area, taking into account their energy, charge, and type. Initially, we estimate the potential number of particles in the nanostructure. Then, we compute the energy required for atomizing the grain from atoms and chemical compounds. By determining the total atomization energy of the grain (Eas), we establish the necessary energy for its formation (Es = 1.1Eas). This energy enables the determination of all characteristics in the ion's action area, such as temperature, temperature rise rate, thermal stresses, strain rate, grain size, volume, and depth of the nanostructure, as well as the actual number of particles in the nanostructure. The calculations demonstrate that the crystallization energy increases the ion energy required to obtain nanostructures. At energies close to 3∙102 eV, it ranges from 0.1 to 7 eV, which can be disregarded, while at energies close to 1.6∙104 eV, crystallization energy ranges from 2.1∙102 to 1.2∙104 eV, with higher values for oxygen ions. Additionally, the calculations show that ion charge significantly affects crystallization energy; for large ion charges, it increases. All of this underscores the necessity of considering crystallization energy only at energies of 2∙103 – 2∙104 eV, allowing refinement of the technological parameters of ion-plasma treatment of aluminum alloys to increase the likelihood of obtaining nanostructures. Furthermore, the ability to determine the sizes of nanostructures allows predicting the physical and mechanical characteristics of surface layers of processed materials. These studies may be of interest to specialists involved in surface strengthening of aluminum alloy surfaces and further research into nanostructures