It's always been bullshirt to compare the ratings of football versus baseball.
One is a weekly sport that doesn't really require much of an investment to follow, which means games outside of usual local interest will do *way* better than the MLB out-of-market equivalent. Casual sports fans flock to football because it's easy.
One is a daily sport that does require time investment to follow correctly. Following baseball is hard, especially if you didn't grow up with it in a MLB market.
The game is very difficult to package in a national sense, try though multiple networks have throughout my life. ESPN tried/tries to do the Turner NBA model of featuring only the most popular teams, but baseball doesn't work the same way. You can't guarantee a Giannis vs. LeBron battle even with two popular teams. You might get No. 5 starter vs. No. 5 starter. (And baseball has hurt itself by devaluing the star value of starters, but that's a different topic for a different thread.)
Baseball falls into the same category as basketball, hockey and MLS. It is intensely followed at a local level, but can be difficult to impenetrable to follow at a national one.
I'd love to know what the combined day-to-day over the course of a week local ratings of baseball would do against football, but even that's not a fair equivalent. The only way it would be if is football was broadcast locally. That's the other massive advantage football has. It has never had to support a local media rights model as other sports do.
Football probably is more popular, but it is, and always has been, an apples-to-oranges comparison from a ratings point of view.
And, of course, ratings themselves take on far, far lesser importance with the fragmented media market. I know it matters in an ad revenue/TV rights sense, but as far as popularity is concerned? This ain't the 80s, where you looked at USA Today's weekly ratings breakdown of three networks that had near-exclusivity. The shirt I watch, some of it sports, some of it not, wouldn't even register in the ratings.