Speed of light is fast, even if possible you'd be looking at a lot of conversion losses. It'd be like trying to use a wire as a battery because power has to travel from one end to the other
I’ve heard of materials that can slow down the speed of light propagation. Imagine you can slow the speed of light to a crawl. You shine a huge amount of light into this material, which has a mirror on the other side. Before your light arrives back at the source, swap it for a mirror. You’ve now got a huge amount of light energy trapped.
Okay, I imagined it. Converting electricity into light is inefficient (maxing out around 44% [1] excluding ballast losses), and converting light into electricity is also inefficient (topping out at 47%[2] efficiency). So you'd end up with a battery that stores energy at extremely low efficiency (less than 21% combined), relying on a hypothetical exotic material that can slow light transmission to ~0.00000001c, assuming you don't mind using a hypothetical box that is 1km long, and you can shine the light and replace the light with a mirror in <1 second. And that's before even accounting for the fact that perfect mirrors do not exist, so you'd be losing another 0.1% of remaining energy with every cycle (i.e. every second)
Or you could buy a lithium-ion battery off the shelf today at 95% round trip efficiency and low self discharge.
Another piece to think about is density. Even with these losses.. how much energy can a material hold in terms of pure light? Is there a limit to how much light can pass through a material?
And I wonder if you could slow the light down even further, maybe 2 or 3 more orders of magnitude..