In this poem, the speaker compares his quest to build connections between his soul and the universe to the way a spider spins a web. In the last lines of the poem, the speaker says he will keeps musing about and attempting to make soul connections until
the bridge you will need be form'd, till the ductile anchor hold,
Till the gossamer thread you fling catch somewhere, O my soul.
A wire or object that is ductile is flexible enough to be drawn out long and thin without breaking. Therefore, a ductile anchor is a long thin thread anchored or attached to something solid, just as a spider attaches the threads at the end of his web to a solid object. Gossamer is something very delicate, light, and almost invisible, such as the threads of a spider's web. The speaker is saying that his soul is like delicate threads extending out across the universe, trying to find a place where they can "catch," or hold.
A spider's web reminds the speaker of his soul because it is delicate and almost invisible, yet strong, too, and reaches out, as his soul does, into the wider world. This reflects Whitman's desire to feel lightly but strongly connected to all beings large and small, near and far. A spider's web inspires him to think it is possible to achieve this sense of connectedness.