It's not free power, as the lights are likely to be dimmer or take slightly more current.
Or did you mean smaller purchase price? It would probably be cheaper than a transformer, but it is certainly more dangerous.
The other problem is lack of a cut-off. Lead-acid batteries should be charged to a fixed voltage, about 14 V for a 12V battery. You circuit will feed the same current even if the voltage goes far above that. You need to monitor the voltage and disconnect if it is too high. If you left it for hours, all the electrolyte would eventually electrolyse into hydrogen and oxygen, and with 240 V available you could get a spark..........