Should I disconnect or leave the power cord on? Does it cost more electricity if it recharges itself again and again or if it has simply been connected to the power grid whenever possible?
The battery life is something with 8 hours in rotation with a reasonably good computer. Calculate yourself how many hours at the can you can save with it.
It doesn't matter, the laptop only draws as much as it needs, as long as the energy saving plan is set the same in battery operation as in mains operation.
Usually, however, the preset energy saving plans are "more radical" in battery mode. But you can also set this yourself for network operation.
Theoretically, some energy is lost when charging the battery, but the bottom line is that you don't notice that.
The most economical would be mains operation, without a battery, with the most radical energy saving options that work.
I almost always have mine on power (because I never know if I'll need the battery for hours later). Only now and then do I let the battery run dry (have read that it would be good for the battery - I don't know if that's true).
But with a battery it saves more electricity, goes out faster, etc.
In any case, my laptop is satisfied, the battery condition is excellent ;-)
It doesn't matter whether you run it on the mains or with a battery. With a battery, the balance of electricity demand can even be slightly higher in one year, as the low losses in charging and the natural discharge of the unused battery require more kWh.
But on the other hand, it is detrimental to the battery if it is constantly (even slightly) supplied with charging current in mains operation; this can affect the service life, so that in the end the overall balance of energy costs shifts.
If you do a lot of mains operation, take out the battery and let it "work" once a month, i.e. To about 10% discharged, recharge to 100% and then put back in the drawer. This guarantees an above-average, but never an infinite, service life.
If the power cord is always connected, you should remove the battery. Otherwise the battery life will be shortened rapidly.
Fully charge the battery then remove it.