Habitat structure alters food availability and predation risk, thereby directly affecting growth, mortality, and size structure of fish populations. Size structure has often been used to infer patterns of resource abundance and predation. However, food availability and predation risk in contrasting habitats have proven difficult to measure in the field. We use an inverse modeling approach to estimate food availability and habitat choice parameters from changes in length distributions of bluegill (Lepomis macrochirus). The model suggests that dynamics of bluegill length distributions primarily reflect food availability and habitat choice. Bluegill behavior minimized effects of size-selective predation on size structure. Parameters for food availability and habitat choice were correlated. It was therefore not possible to attain unique estimates of food availability and habitat selection when both were free parameters. However, when one parameter was estimated independently, the other could be identified. In five Wisconsin lakes, seining studies were used to estimate the size at which bluegill switched from littoral to pelagic habitats. Using this measure of switch size in the model, we estimated food availability for bluegill in each lake. These estimates were positively correlated with observed growth (r2 = 0.91), demonstrating the model's ability to estimate food availability.