Good bread has a crust that needs to breathe. Seal it in plastic and that crust goes soft within hours; leave it uncovered and the crumb dries out. The answer is somewhere in between.
For a sourdough loaf, keep it cut-side down on a wooden board for the first day, then move it to a paper bag or a cloth bread bag. A bread bin with a little ventilation does the same job. Stored this way a loaf stays good for three days, and makes excellent toast for two more.
Never put bread in the fridge. The cold speeds up the process that makes bread stale, so a loaf that would last three days on the counter goes hard in one.
The freezer is your friend. Slice the loaf before freezing, and you can toast slices straight from frozen whenever you need them. Baguettes and croissants also freeze well; refresh them in a hot oven for five minutes and they come back almost as good as new.