The theme is expansion, growth and the hope that life will improve and become refined over time.
The narrator describes a nautilus, the "ship of pearl, which, poets feign, Sail the unshadowed main." It is a strange creature, indeed, that year after year, builds its home, chamber after chamber, in a spiral of mathematical perfection. ("Year after year beheld the silent toil That spread his lustrous coil").
The inner creature eventually outgrows a chamber only to move, circle-like, into the next, more spacious chamber ("Still, as the spiral grew, He left the past year's dwelling for the new").
In the end, the narrator sees the life of the nautilus as a hidden message of human life, to ever build "more stately mansions" for the soul to inhabit, so that, at life's end it may be ready and worthy to inhabit heaven above.
Coincidentally, just last week I took a picture of a painted nautilus in a shop window. See the first link below.