The addition of storage technologies such as flow batteries, conventional batteries, and heat storage can improve the economic, as well as environmental attraction of micro-generation systems (e.g., PV or fuel cells with or without CHP) and contribute to enhanced demand response. The interactions among PV, solar thermal, and storage systems can be complex, depending on the tariff structure, load profile, etc. In order to examine the impact of storage technologies on demand response and CO2 emissions, a microgrid's distributed energy resources (DER) adoption problem is formulated as a mixed-integer linear program that can pursue two strategies as its objective function. These two strategies are minimization of its annual energy costs or of its CO2 emissions. The problem is solved for a given test year at representative customer sites, e.g. nursing homes, to obtain not only the optimal investment portfolio, but also the optimal hourly operating schedules for the selected technologies. This paper focuses on analysis of storage technologies in micro-generation optimization on a building level, with example applications in New York State and California. It shows results from a two-year research project performed for the U.S. Department of Energy and ongoing work. Contrary to established expectations, our results indicate that PV and electric storage adoption compete rather than supplement each other considering the tariff structure and costs of electricity supply. The work shows that high electricity tariffs during on-peak hours are a significant driver for the adoption of electric storage technologies. To satisfy the site's objective of minimizing energy costs, the batteries have to be charged by grid power during off-peak hours instead of PV during on-peak hours. In contrast, we also show a CO2 minimization strategy where the common assumption that batteries can be charged by PV can be fulfilled at extraordinarily high energy costs for the site.