An X-ray grating interferometer (GI) suitable for clinical mammography must comply with quite strict dose, scanning time and geometry limitations, while being able to detect tumors, microcalcifications and other abnormalities. Such a design task is not straightforward, since obtaining optimal phase-contrast and dark-field signals with clinically compatible doses and geometrical constraints is remarkably challenging. In this work, we present a wave propagation based optimization that uses the phase and dark-field sensitivities as figures of merit. This method was used to calculate the optimal interferometer designs for a commercial mammography setup. Its accuracy was validated by measuring the visibility of polycarbonate samples of different thicknesses on a Talbot-Lau interferometer installed on this device and considering some of the most common grating imperfections to be able to reproduce the experimental values. The optimization method outcomes indicate that small grating pitches are required to boost sensitivity in such a constrained setup and that there is a different optimal scenario for each signal type.