John Lennon was inspired to write the song after he felt he was being perpetually nagged by his wife Cynthia, one night in 1967. As Cynthia was telling him the same thing over and over, he came up with the lyrics, words are flowing out like endless rain into a paper cup.
After Cynthia went to bed, Lennon proceeded downstairs to write his new song. He added some more lyrics on paper but the following morning completely forgot about them.
“But the words stand, luckily, by themselves. They were purely inspirational and were given to me as boom! I don’t own it, you know; it came through like that. I don’t know where it came from, what meter it’s in, and I’ve sat down and looked at it and said, ‘Can I write another one with this meter?’ It’s so interesting: ‘Words are flying [sic] out like [sings] endless rain into a paper cup, they slither while they pass, they slip away across the universe.’ Such an extraordinary meter and I can never repeat it! It’s not a matter of craftsmanship; it wrote itself. It drove me out of bed. I didn’t want to write it, I was just slightly irritable and I went downstairs and I couldn’t get to sleep until I put it on paper, and then I went to sleep.
It’s like being possessed; like a psychic or a medium. The thing has to go down. It won’t let you sleep, so you have to get up, make it into something, and then you’re allowed to sleep. That’s always in the middle of the bloody night, when you’re half awake or tired and your critical facilities are switched off.” – John Lennon