While optical surveys regularly discover slow transients like supernovae on their own, the most common way to discover extragalactic fast transients, which fade within a few nights in the optical, is via follow-up observations of gamma-ray burst and gravitational-wave triggers. However, wide-field surveys have the potential to also identify rapidly fading transients, including counterparts to multimessenger sources, independently of such external triggers. The volumetric survey speed of the Zwicky Transient Facility (ZTF), in particular, makes the survey sensitive to objects that are as faint and fast-fading as kilonovae, the optical counterparts to binary neutron stars and neutron star-black hole mergers, out to almost 200 Mpc. In this paper, we introduce an open-source software infrastructure, the ZTF REaltime Search and Triggering, ZTFReST, which is designed to identify kilonovae and fast optical transients in ZTF data. Using the ZTF alert stream combined with forced point spread function photometry, we have implemented automated candidate ranking based on their photometric evolution and fitting to kilonova models. Automated triggering of follow-up systems, such as Las Cumbres Observatory, for sources that pass user-defined thresholds, has also been implemented. In 13 months of science validation, we found several extragalactic fast transients independent of any external trigger (though some counterparts were identified later), including at least one supernova with post-