The Road, though undeniably bleak, ends on a note of hope. The boy has learned to "carry the fire." In other words, his father was successful in teaching him not only how to survive but especially how to maintain their basic code of morality and right action under the most challenging and depressing conditions. Even though the boy's mother gave up, they will not do the same—they will not become suicidal, they will not become raiders, slavers, rapists, or cannibals. They will maintain their humanity despite the unrelenting grey desolation that has led so many around them sink to the level of predatory beasts.
After enduring so many hardships, the father and his son are successful in their quest to follow the road to the coast. The father completed his mission before his death. The boy stays with his father's corpse. Perhaps he is not sure what to do next. His father trained him not to be taken alive by raiders to be tortured, enslaved, or cannibalized. That is what the last bullets in the gun were for—just in case. Other than that, he was to carry on and "carry the fire."
Eventually, another group of "good guys," a mother and father with children, find the boy and adopt him into their family. This shows us that the entire struggle was worthwhile. The struggle of the father and son was not in vain. In this new family, the goodness in humanity will survive in spite of the badness all around them. That is the message of hope that I found at the end of The Road.