That's a big topic Charriot. I'll just scratch the surface with two points.
1. You need to use the right battery for the purpose. The main types of concern to us yachties are starting batteries and storage batteries. A starting battery - eg a typical car battery - can supply very high current for short periods, and can then recharge rapidly. They are typically measured in CCA (Cold Cranking Amps), ie the amount of current they can supply for a certain period. So a 600CCA battery can supply 600A for (say) 15 seconds. These batteries can not withstand deep discharge. In a typical yacht, you should use a starting battery for your engine starting - but because of a diesel's high compression, the battery needs to be a heavy-duty type.
A storage battery is bigger, heavier and more expensive. It is designed to cycle regularly between full charge and a partially discharged state. This is what you should use to power your lights and refrigeration. Storage batteries are measured in AH - eg, a 100AH battery can supply, say 10A for 10 hours; or 1A for 100 hours. BUT - see below about depth of discharge.
Both types of batteries can be either open (with caps on each cell for you to add distilled water) or sealed ("low maintenance", "agm", "vrla", "gel").
2. You need to look after batteries to get the most life out of them. This means proper charging (there are books written about just these 2 words); avoiding long periods (ie weeks) at a partially discharged state; and avoiding deep discharge. Most storage batteries should not be discharged below 50% (so you should only use 50AH from a 100AH battery). All lead-acid batteries will self-discharge, at different rates depending on the technology. Eg an unused conventional battery needs a "top-up" charge every few weeks, while an AGM battery would be OK for several months.
Many different battery types contain calcium - on its own, this does not mean much. But 5 years isn't bad - if the batts are abused they could be dead in 2 years or less, high or low quality regardless. My current gel house batteries are about 10 years old (I've only owned them for the last 4) but I think only have 1 or 2 seasons left. When the time comes to replace it will be either AGM or LiFeP04.
en.wikipedia.org/wiki/Lead%E2%80%93acid_batterybatteryuniversity.com/learn/