I don't know for sure, but after a brief look at the code, I think it's hardcoded in places like spm_spm.m, e.g. the line Vbeta(i).fname = sprintf('beta_%04d.img',i); This is then passed to Vbeta = spm_create_vol(Vbeta); and spm_create_vol decides on format based on the extension given in the filename.