Introducing synthetic fuels and biofuels like biodiesel can be pivotal in transitioning to a decarbonised energy system. Biodiesel offers a versatile solution with various production technologies, each with advantages and disadvantages, depending on several factors, including the specific application of biodiesel. In a smart grid, an advanced electrical grid that leverages digital technology to detect and respond to local changes in usage, a small community could harness biodiesel for energy storage and supply. By implementing a renewable energy storage system in the form of biodiesel from waste oils, individuals can contribute to developing innovative solutions for the combined and distributed production of electricity and heat, primarily from renewable sources. The aim is to make the production-demand distribution networks within a hybrid system smart and in line with the concept of nanogrid. This localised grid can operate independently or in conjunction with the traditional power grid and can integrate generation systems from fossil and renewable sources, micro-cogeneration, and accumulation. The possibility of exploiting biodiesel in a nanogrid as an eco-sustainable source for energy storage opens up the possibility of building small-scale plants. For example, converting 3682 L/year of waste oils from a university campus dining facilities to 3712 L/year of biodiesel allows replacing 19% of the fossil diesel consumed by the university fleet, with a payback period of 16 months, lower capital and operational costs, and reduced greenhouse gas emissions of 9.37 tonnes CO2-eq/yr. Therefore, biodiesel becomes a sustainable energy source for energy communities, underscoring the innovative potential of this approach.