  Phase-separated semiconductors containing magnetic nanostructures are
relevant systems for the realization of high-density recording media. Here, the
controlled strain engineering of Ga$\delta$FeN layers with Fe$_y$N embedded
nanocrystals (NCs) \textit{via} Al$_x$Ga$_{1-x}$N buffers with different Al
concentration $0<x_\mathrm{Al}<41$\% is presented. Through the addition of Al
to the buffer, the formation of predominantly prolate-shaped
$\varepsilon$-Fe$_3$N NCs takes place. Already at an Al concentration
$x_\mathrm{Al}$\,$\approx$\,5\% the structural properties---phase, shape,
orientation---as well as the spatial distribution of the embedded NCs are
modified in comparison to those grown on a GaN buffer. Although the magnetic
easy axis of the cubic $\gamma$'-Ga$_y$Fe$_{4-y}$N nanocrystals in the layer on
the $x_\mathrm{Al} = 0\%$ buffer lies in-plane, the easy axis of the
$\varepsilon$-Fe$_3$N NCs in all samples with Al$_x$Ga$_{1-x}$N buffers
coincides with the $[0001]$ growth direction, leading to a sizeable
out-of-plane magnetic anisotropy and opening wide perspectives for
perpendicular recording based on nitride-based magnetic nanocrystals.
