That used to be more true in the past, but recently OTA's are beginning to offer better rewards programs, as well as making your trip more 'interconnected' (having one place to get flight, hotel, cars, events, activities, etc.), so now I'd say "it depends". Lately though, the bigger hotel chains themselves are also starting to introduce their own rewards, so we'll see what happens
One time I had a not so nice experience with a hotel. They promised a partial refund, but also a threat that they'll re-charge my CC the full amount if I wrote a bad review. No such refund came, I wrote a bad review, then they talked to me and did actually refund me. But how could they re-charge my CC without the CC info? I smell a violation of PCI DSS there.
The UI of hotels website is also often terrible and I absolutely do not trust them with my credit card info (nor do I wish to send them a SEPA deposit which I have seen at more than one place).
For flights on the other hand I take the airline website any day.
Sometimes identifying “the airline” isn’t straightforward.
Found a great routing+price: Toronto-Philadelphia-Paris on an OTA, all on AA metal.
But the fare wasn’t available on AA.com, you had to find it on Iberian’s website which booked some of the legs through a Finnair codeshare.
So had to book on booking.com and other multinational sites.
I know anecdotes aren't data, but I've had the opposite experience.
Front Desk: "Hey, I see you booked with Expedia. You know if you booked directly with us, you'd get a better rate!"
Me: "Oh really? Thanks! Can I book tomorrow night at the same rate as tonight?"
Front Desk: "No, sorry, tomorrow night's rate is twice as the rate you have from Expedia."
Me: "Ok, I guess I'll book at Expedia for tomorrow night as well, since they have the same rate that's half of what you're offering me."
I've had this happen so many times!
When asked directly, they just tell me to book on Booking.com.
Having worked at an OTA (before Expedia got us) I refuse to book at anything other than a legit hotel system. OTA's are fine for price discovery but you often get a better deal (and better service) from the hotel/brand directly. The front desk knows you booked via an OTA instead of the hotel directly.