Best time to cook chicken, to keep it from going off
The best time to cook is "now" as it gives germs less time to multiply.

If you have a slow cooker, sous-vide set-up, you can keep the cooked meat for up to 21 days in the fridge (for months in the freezer).

I must direct you to this previous question for more info on food safety.

Edit: If your goal is, as stated, to maximize the time you have chicken in your fridge without getting sick, 3 days + 4 days will give you seven days. However, from a food quality point of view, cooking "now" will give you more satisfaction.

Something else... you don't know how long the chicken has been dead already. I've seen some nasty looking chicken at butchers. If the skin looks dry, it has been dead for some time already.