Gerry Marsden famously admitted on the south bank show, handing a recording of YNWA to Shankly before he released it citing it's motivational effects on other teams. The Song had already been adopted by Celtic fans and Marsden decided to release it on hearing it sang by them and being requested to by a disabled Celtic fan.
You can go to Wiki and see that the author of the page on there is clearly a liverpool fan who cannot accept the clubs anthem was first someone elses.
You can go read the Guardian online, the sports writer on there makes no conclusion as to whether the song was first sang by LFC or Celtic fans becoz they started to sing it so close together in time.
But, stories have it that the kop only adopted the song after the song had been at no1 for many weeks. The DJ within the club would play the weekly top ten before the match, YNWA spent that long at no1 that the first week it fell away, the Liverpool supporters sang it anyway.
Shankly took note and made it a custom.
What most people negate to mention tho is, Hereford United supporters were singing the song long before. The song originally came from a musical and there was some connection with the writers and Hereford, cant remember what it was but I had it proved to me by a Celtic Fan when I was serving overseas, and he showed me a Book that proved me wrong.