Over the past few years, wide-field time-domain surveys such as Zwicky Transient Facility and Optical Gravitational Lensing Experiment have led to discoveries of various types of interesting short-period stellar variables, such as ultracompact eclipsing binary white dwarfs (WDs), rapidly rotating magnetized WDs, transitional cataclysmic variables between hydrogen-rich and helium accretion, and blue large-amplitude pulsators (BLAPs), which greatly enrich our understandings of stellar physics under some extreme conditions. In this paper, we report the first-2-yr discoveries of short-period variables (i.e. P < 2 h) by the Tsinghua University–Ma Huateng Telescopes for Survey (TMTS). TMTS is a multitube telescope system with a field of view up to 18 deg2, which started to monitor the Large Sky Area Multi-object Fiber Spectroscopic Telescope (LAMOST) sky areas since 2020 and generated uninterrupted minute-cadence light curves for about 10 million sources within 2 yr. Adopting the Lomb–Scargle periodogram with period-dependent thresholds for the maximum powers, we identify over 1100 sources that exhibit a variation period shorter than 2 h. Compiling the light curves with the Gaia magnitudes and colours, LAMOST spectral parameters, International Variable Star Index classifications, and archived observations from other prevailing time-domain survey missions, we identified 1076 as δ Scuti stars, which allows us to study their populations and physical properties in the short-period regime. The other 31 sources include BLAPs, subdwarf B variables, pulsating WDs, ultracompact/short-period eclipsing/ellipsoidal binaries, cataclysmic variables below the period gap, etc., which are highly interesting and worthy of follow-up investigations.