To understand the development of infant comprehension of visual obstructions and perspective-taking, this study tested the ability of N = 28 infants at 14, 16, and 18 months to adapt attention-sharing to visual constraints. An experimental task investigated how infants modify gaze following behaviors when an adult’s line of sight is obstructed by a barrier. From 14 to 18 months, infants gradually learned to modify their search behavior when an adult looked toward a referent hidden behind a barrier from the infant’s perspective. This suggests development of perspective-taking during this period. It also reveals age-related changes in infants’ understanding of contextual effects on others’ referential gaze in visually complex environments. Furthermore, the results address debates about “rich” versus “lean” theories of shared attention and intentionality.