Better a day too soon than a moment too late - we don't use the phrase 'putting them out of their misery' for nothing. Once the quality of life has gone, when a previously clean dog cannot get out to relieve itself, when its special food is no longer tempting and when that loving welcome is now just a struggle to even get up to greet you then you know the time has come to help them go in peace and dignity, which is something we cannot do for our human friends and family. It never gets easier, but the relief once the decision is made definitely tells you it was the right thing to do. Cherish the memories.