We investigated the degree of flexibility in retention strategies of young fishes in the low-salinity zone (LSZ) of the San Francisco Estuary during years of highly variable river flow. We conducted depth-stratified sampling over three full tidal cycles in each year from 1994 to 1996. In 1994, exotic striped bass (Morone saxatilis), native longfin smelt (Spirinchus thaleichthys), and exotic yellowfin goby (Acanthogobus flavimanus) migrated tidally, occurring near the surface on flood tides and near the bottom on ebb tides. This strategy may have facilitated retention, because landward residual currents were absent in this drought year. During 1995, this behavior persisted for striped bass and yellowfin goby, even though landward residual currents were present under high river-flow conditions. In moderate river-flow conditions (1996), longfin smelt again migrated tidally, whereas at another station adjacent to shallow bays, longfin smelt, striped bass, and native delta smelt (Hypomesus transpacificus) migrated on a reverse diel cycle, occurring near the surface by day and at depth by night. Reverse diel migration may facilitate horizontal transport and retention. Therefore, young fishes appeared to be behaviorally flexible in different environmental conditions to maximize retention. Vertical migrations may also enhance feeding success because zooplankton prey similarly migrated in the LSZ. Our study underscores the value of interdisciplinary studies in a variety of environmental conditions to decipher the range of organism behaviors promoting transport and retention in optimal habitats.