The poem was inspired by an event on 15 April 1802, in which Wordsworth and his sister Dorothy came across a "long belt" of daffodils. Written some time between 1804 and 1807 (in 1804 by Wordsworth's own account), it was first published in 1807 in Poems in Two Volumes, and a revised version was published in 1815.

Based on this passage, when was i wandered lonely as a cloud published? Let's give stream of consciousness first:
To answer this question, we should know that: Written some time between 1804 and 1807 (in 1804 by Wordsworth's own account), it was first published in 1807 in Poems in Two Volumes, and a revised version was published in 1815.
So, the final answer is 1807.