Researchers at Columbia University Law School Addressed this well in their paper: “Rebutting 33 False Claims About Solar, Wind, and Electric Vehicles“. Here’s what they had to say:
Ambitious solar deployment would utilize a relatively small percentage of U.S. land when compared to the land currently being used for agriculture. The Department of Energy estimated that total U.S. solar development would take up roughly 10.3 million acres in a scenario in which cumulative solar deployment reaches 1,050–1,570 GW by 2050, the highest land-use scenario that DOE assessed in its 2021 Solar Futures Study . If all 10.3 million acres of solar farms were sited on farmland, they would occupy only 1.15% of the 895,300,000 acres of U.S. farmland as of 2021. However, many of these
projects will not be located on farmland.
Furthermore, solar arrays can be designed to allow, and even enhance, continued agricultural production on site. This practice, known as agrivoltaics, provides numerous benefits to farmers and rural communities, especially in hot or dry climates. Agrivoltaics allow farmers to grow crops and even to graze livestock such as sheep beneath or between rows of solar panels. When mounted above crops and vegetation, solar panels can provide beneficial shade during the day.
Multiple studies have shown that these conditions can enhance a farm’s productivity and efficiency. One study found, for example, that “lettuces can maintain relatively high yields under PV” because of their capacity to calibrate “leaf area to light availability.” Extra shading from solar panels also reduces evaporation, thereby reducing water usage for crops by around 14-29%, depending on the level of shade. Reduced evaporation from solar installations can likewise mitigate soil erosion. Solar farms can also create refuge habitats for endangered pollinator species, further boosting crop yields while supporting native wild species. Overall, agrivoltaics can increase the economic value of the average farm by over 30%, while increasing annual income by about 8%. Farmers in other countries have begun implementing agrivoltaic systems.
As of March 2019, Japan had 1,992 agrivoltaic farms, growing over 120 different crops while simultaneously generating 500,000 to 600,000 MWh of energy. Furthermore, the argument that solar development will imperil the food supply is belied by the fact that tens of millions of acres of farmland are currently being used to grow crops for other purposes, such as the production of corn ethanol.
Currently, roughly 90 million acres of agricultural land in the United States is dedicated to corn, with nearly 45% of that corn being used for ethanol production. Solar energy could provide a significantly more efficient use of the same land. Corn-derived ethanol used to power internal combustion engines has been calculated to require between 63 and 197 times more land than solar PV powering electric vehicles to achieve the same number of transportation miles.
If converted to electricity to power electric vehicles, ethanol would still need roughly 32 times more land than solar PV to achieve the same number of transportation miles. And even when accounting for other energy by-products of ethanol production, solar PV produces between 14 and 17 times more gross energy per acre than corn. The figure below contrasts the land use requirements of solar PV with dedicated biomass and other energy sources. Whereas dedicated biomass consumes an average of 160,000 hectares of land per terawatt-hour per year, ground-mounted solar PV consumes an average of 2,100.

Finally, while solar installations, like any infrastructure projects, will inevitably have some adverse impacts, the failure to build the infrastructure necessary to avoid climate change poses a far more severe threat to agricultural production. Climate change already harms food production across the country and globe through extreme weather events, weather instability, and water scarcity.
The most recent Intergovernmental Panel on Climate Change (IPCC) report forecasts that climate change will cause up to 80 million additional people to be at risk of hunger by 2050. A 2019 IPCC report forecasted up to 29% price increases for cereal grains by 2050 due to climate change. These price increases would strain consumers globally, while also producing uneven regional effects.128 Moreover, while higher carbon dioxide levels may initially increase yield for certain crops at lower temperature increases, these crops will likely provide lower nutritional quality.129 For example, wheat grown at 546–586 parts per million (ppm) CO2 has a 5.9–12.7% lower concentration of protein, 3.7–6.5% lower concentration of zinc, and 5.2–7.5% lower concentration of iron.130 Distributions of pests and diseases will also change, fuels.