There are lots of variables; the wine type, method of production, age and so on. There are all those considerations and exceptions but for 95% of the wine that people drink every day, the answer is pretty simple.
Three Days: At home, I can keep wines up to 3 days after the bottle has been opened, (this doesn't happen very often). Once a bottle of wine is opened, the oxygen in the air starts a process that brakes-down the fruit flavours and releases, opens up and diminishes the aromas. As this process (also known as oxidation) continues over hours and days, the wine is ultimately undrinkable; the trick is to enjoy the wine before this point. You can (and usually should) refrigerate or store in a cool, dark place re-closed (open) bottles. You can buy wine-gadgets to create a seal / slight vacuum in the bottle.
You can also purchase hand-held or larger units that put a layer of inert gas inside the bottle. All these efforts are aimed at slowing down the oxidation that will eventually degrade the wine. What makes the whole thing tricky is that wine will not immediately/ instantly go from good to bad. Also each person has a different point at which they identify the wine as having started to turn of worse has gone bad.
• A good example: *(If you are working in hospitality - try if possible to have only one person smelling all your wines served 'by the glass' during each shift, this is to reduce variations to the same customer, table and throughout the restaurant).
If you want to play it safe (and who doesn't with your favourite bottle of wine), use the 3 day rule, (though during summer or in hot climates this can be reduced). Re-close and refrigerate the bottle for up to 3 days. With red wines, remember to take the bottle out from the fridge at least 1 hour before you want to enjoy it - so it can warm up to a temperature of around 16°- 18°C depending upon the red wine style.
• Also please note - that the average temperature of a home refrigerator is between 2°- 4°C. So even with White wines or Rosés, depending upon the room temperature and time of year, please give the wine 10-15 minutes or so to get up to about 8°- 10°C the ideal drinking temperature.
If you keep a wine for more than 3 days, you will be serving a wine that has lost most of the personality and characteristics that are prized and why you chose the wine to share. The aroma will start to change and much of the fresh fruit aromas and vibrant flavours will be subsided, or even lost. At worse, you will be serving a wine that has completely oxidized and has gone bad, sour, even aggressive like a vinaigrette.
• Dessert / Sweet Wines, Ports & Sherries can last longer - but those are special cases (due to the method of production, increased sugar levels and the higher alcohol content, which can act as a preservative and slow the process). In general play it safe with the 3 day rule, but always smell the wine before pouring any glass of any age. *(one last detail - if the wine is not good enough to drink, please do not cook with it)