Metal-organic chemical vapor deposition (MOCVD) is one of the best growth methods for GaN-based materials as well-known. GaN-based materials with very quality are grown the MOCVD, so we used this growth technique to grow InAlN/GaN and AlN/GaN heterostructures in this study. The structural and surface properties of ultrathin barrier AlN/GaN and InAlN/GaN heterostructures are studied by X-ray diffraction (XRD) and atomic force microscopy (AFM) measurements. Screw, edge, and total dislocation densities for the grown samples have been calculated by using XRD results. The lowest dislocation density is found to be 1.69 x 10(8) cm(-2) for Sample B with a lattice-matched In0.17Al0.83N barrier. The crystal quality of the studied samples is determined using (002) symmetric and (102) asymmetric diffractions of the GaN material. In terms of the surface roughness, although reference sample has a lower value as 0.27 nm of root mean square values (RMS), Sample A with 4-nm AlN barrier layer exhibits the highest rough surface as 1.52 nm of RMS. The structural quality of the studied samples is significantly affected by the barrier layer thickness. The obtained structural properties of the samples are very important for potential applications like high-electron mobility transistors (HEMTs).