We use models to show how a variable environment can affect development, survival and timing of metamorphosis of meroplanktonic larvae. For a general case, we use an analytical model to explore the effect of temperature-dependent development and mortality rates on temporal patterns of metamorphosis. The distribution of metamorphosis over time is a lagged version of the pattern of larval release, distorted by changes in development and mortality rates. If temperature causes development rate to increase (decrease) linearly with time through the larval period, the timing of metamorphosis has a short (long) temporal range, a large (small) amplitude, and is shifted to the left (right). This implies that at locations with a decreasing trend in development rate (e.g. due to decreasing temperature), the timing of metamorphosis is more sensitive to larval release time than at locations with an increasing trend. Mortality of larvae can be influenced directly by the environment through sub-optimal conditions, or indirectly by environmentally induced changes in development rate, which change the duration of the larval period. If mortality rate is constant, the longer the larval period the greater the mortality. However, this result is not true if mortality rates change with the environment in the same way that development rates change. The common assumption of constant mortality rates needs to be critically reassessed. To apply these results to a specific example, we develop a model of the temperature- and salinity-dependence of Dungeness crab Cancer magister Dana larval development, using available laboratory data. We then use historical records of daily sea surface temperatures and salinities to examine the impact of these 2 variables on larval development and survival at coastal sites along the U.S. west coast. Based on calculations from 7 locations over a total of 233 yr, Dungeness crab larvae can take between 74 and 182 d to metamorphose, depending on location, year and time of release. Larvae in the northernmost part of the study region (Washington) have the longest mean annual development times (133 to 163 d), those in central and northern California have intermediate development times (81 to 134 d), and those in southern California have the shortest development times (74 to 84 d). Greatest relative intra- and interannual variability in mean development times and survival occurred in upwelling areas off central California. Observed latitudinal differences in timing of metamorphosis from zoeal to megalopal stages were consistent with differences predicted by the model. We conclude that variability in temperature and salinity can cause Dungeness crab larval periods to vary by a factor of 2. For meroplanktonic populations in general, complicated patterns of metamorphosis can result from variable temperatures during the larval period, even if hatching of larvae occurs at a constant rate.