The speaker in the first two lines of this poem is describing the "lonely" state in which he found himself before encountering the "crowd" of daffodils while out walking. He compares himself to a cloud, suggesting that he felt untethered, unconnected to the world around him, and as if he were simply floating over the "vales and hills" below.
However, when he sees the daffodils, his mood immediately changes. The use of the word "crowd" seems significant here, as a contrast to the speaker's previous loneliness. Where he is single and isolated, the daffodils are "never-ending," defined by the sheer quantity of them. They are also extremely cheerful: the speaker describes them as "jocund company" and notes that they seemed as if they were dancing. This, the speaker declares, made it impossible for him to feel anything other than "gay."
In the final stanza of the poem, the speaker describes how he uses this memory to shore him up when he is lying on his couch and feeling "pensive" or unhappy. The wealth offered to him by the sight of the daffodils does not last only for a single moment, but is capable of giving him "pleasure" when he recollects it after the fact. This is an example of Wordsworth's theory that nature can be "recollected in tranquillity" to give pleasure to the soul, as if the beautiful things in nature can be stored up to give us solace when we are feeling low.