There has been a vibrant community gardening movement in New York City since the 1970s. The movement is predominantly located in working class communities of color and has fought for decades to turn vacant land into beneficial community spaces. However, many of these communities are struggling with gentrification, which has the potential to transform access to and use of community gardens in the city and the politics around them. Drawing on separate multi-year ethnographic projects, this article compares two community gardens in food insecure communities in Queens and Brooklyn: one that is undergoing gentrification and one that is not. We analyze how race and class transformations in each community shape the trajectories of urban agriculture spaces, specifically the ideologies, agricultural practices, and daily interactions among gardeners and as well as between gardeners and nongardeners. We find significant differences in how the two sets of community gardeners conceptualize the purpose of their gardens, particularly in constructing them as green spaces, agricultural production sites, and tools for achieving food justice. We argue that these differences can be best understood at the intersection of the personal histories of individuals, the organizational settings in which the gardens are embedded, and each neighborhood’s history of urban renewal and gentrification. Our findings show why some community gardens in food insecure communities adopt a food justice vision, while others do not, and how gentrification can amplify racial and class tensions within community gardens and between gardeners and nongardeners.