In the first stanza, the eponymous "clock man" asks a child how much the child will pay "for an extra day" and the child replies "Not one penny." The child refuses to pay even a penny for the extra day, because they have so many days ahead of them. Indeed, to a child, time seems endless and thus of little value.
In the second stanza of the poem, the "clock man" asks the same question of the same child, when that child is a few years older. The "grown" child replies that they will pay "Maybe a dollar or maybe less." The "grown" child still doesn't understand the true value of time, because they are still young and thus have many days ahead of them. However, the "grown" child has fewer days ahead of them than when they were first asked the question and so is willing to pay something, albeit not much, for the offered extra day.
In the third and final stanza of the poem, the "clock man" asks the same question again, but this time, the child is older and about to die. This time, the older child replies that they will pay "All of the pearls in all of the seas / And all of the stars in the sky" for the offered extra day. Now that the older child has no more days to live, they understand the true value of time. They understand that even one single day is more precious and more valuable than any amount of money or riches.
The moral of the poem is that we should appreciate more the value of time. There is also an irony in the poem in that we are only able to appreciate the true value of time when we have run out of it. If we were perhaps able to appreciate the value of time when we still have lots of it left, then perhaps we might make more of that time than many of us do.