The effective life of a pumpkin when not exposed to rain or snow is about a week, depending on conditions. The two threats to a pumpkin are dehydration (which causes the pumpkin to shrivel up) and mold. After about three days, pumpkins will begin to have evidence of mold and start softening. How long you are willing to keep your pumpkins around after that depends on personal preference.
There are various options for attempting to extend the life of a pumpkin. These include soaking the pumpkin in a mixture of water and bleach, spreading vaseline on the pumpkin, or commercial mixtures such as the Pumpkin Fresh spray. One person online conducted a science experiment to test the various options and posted his results. Under ideal conditions with these methods, your pumpkin won’t last more than two weeks.