In this article, we propose variable-period diffraction gratings for terahertz frequencies. The design, fabrication and characterization of such devices are presented. Our measurements show the possibility to actively shift of the deflection angle for each frequency using this device. We also demonstrated that, when driven by a speaker, these variable gratings can be used for active beam steering with potential application in terahertz communications.