The 22-year-old, who was with Arsenal as a youngster, was playing in the Essex Senior League with Stansted until 2011.
And he only turned professional with Dagenham and Redbridge 12 months ago after scoring 29 goals during a loan spell at Conference North outfit Bishop's Stortford.
But Gayle then made a major impact last season with 20 goals in total for the Daggers and Peterborough, who he joined initially on loan in November, to catch Holloway's eye.
Holloway said: "I'm absolutely delighted. I was very annoyed when we didn't get him last year, to be honest.
"But now it makes a huge statement for us and it proves that I don't care where I get my people from. I believe it's about how good you're going to be, not just how good you are already.
"I think this fella has got Crystal Palace stamped all over him - the way he moves, the way he chases, the way he works. He's hungry for success and I'm absolutely thrilled that after long conversations we've come up with, I think, a proper Palace player.
"He's got an opportunity now to go and enjoy his football and I think he'll score goals at Premier League level, I really do. He's born to score goals."