Being a collect-a-thon, Yooka-Laylee will not be the same length for every player. Your mileage will vary depending on how thoroughly you'll play through each level.
However, if we're talking the barebones, you'll need to collect 100 Pagies total (which includes Pagies you already used to unlock and expand worlds) in order to gain access to the final boss fight. Unlocking that many Pagies can easily take you a good 15-20 hours, and the final boss fight can take you 1-3 hours to complete.
Also Read: 5 Tips I Wish I Knew Before Starting Yooka-Laylee
All in all, we're looking at anywhere from 16-23 hours, and that's the bare minimum. For 100% completion, there are 145 Pagies and even more collectibles, so you're likely going to log 30+ hours for that achievement.