An interesting heuristic I came up with is that we should install 1 kWh of batteries for every kilowattpeak (kWp) of solar panels. On average solar panels will output around 20% of their rated peak power worldwide (see table). A good rule of thumb is that you want a minimum of 5 hours of storage in the future renewable grid. Five times 20% is 100%, hence 1 kWh of batteries for 1 kWp of solar panels.
This shows the Germany having only 11-12% capacity factor for solar? I assumed it was close to Spain's figure