Yes, Definitely, books are worth it. I was at the same place as of you ~3 years ago, doubting the value of reading books - so, I can speak to it.

tl;dr: For breadth, online reading is good enough; while for depth and study, books tend to be the way to go. No matter which medium(book/audiobook/summaries), reading more is always better.

I can think of at least 4 major differences between online content and books.
1. Comprehensiveness
2. Background research
3. Test of time
4. Focus and grounding

Let me explain.

1. Most of the online content is "designed" to be consumed in < 10 minutes. So, it assumes fundamentals or ignores details otherwise are critical to the topic. This is useful for quickly grasping a concept, but if you want to go deeper, books will give you better context

2. "92% of the online content is designed to prove a point"
(Above statement is a made-up one, and I have no idea what percentage of the online content is made up)

A lot of content available online are valuable and accurate. At the same time, the credibility of online content is questionable, while books tend to be more research-oriented. A person has spent at least 6 months to put together a book, and multiple people spend hours to get it out. Books tend to be more linked to the credibility of the author. Paul Graham's essays (http://paulgraham.com/articles.html), for example, are gems and it doesn't matter if it is consumed as a book or a blog - it does contain valuable content.

3. Books age well than online content - some of the timeless classics still stay relevant in the current decade or century. More people review them, so more crowdsourced opinions. This might sound contrary to the belief, but this is something I've observed over time.

4. Most importantly, you may devour the internet for a whole day, and learn a bunch of things but the very next day, because everything was so unstructured, you'd tend to lose clarity and only a few things stick. This is more pertinent to some people than others. So, consuming or learning about new concepts systematically through a book will improve the stickiness of the ideas and be more structured while thinking about it. Books, also tend to be more detailed with more examples to put things in context, to which you can relate to. It gives you time to think and organize. Think about it as taking a structured course, rather than learning bits and pieces from here and there.

Now, the Pareto Principle (80/20) does apply and reading 20% will give you general context on 80%. But more often than not, on most subjects, 20% does contain in-depth information you'll miss out on.

Listing a few books I recommend, which I believe are worth reading

[1] The Science of the Artificial by Herbert A. Simon
[2] Gödel, Escher, Bach: An Eternal Golden Braid by Douglas Hofstadter
[3] Maps of Meaning: The Architecture of Belief by Jordan Peterson
[4] Homo Deus: A History of Tomorrow by Yuval Noah Harari
[5] A New Earth: Awakening to Your Life's Purpose by Eckhart Tolle
[6] Antifragile: Things That Gain from Disorder by Nassim Nicholas Taleb
[7] Beyond Good and Evil by Friedrich Nietzsche
[8] The Origins and History of Consciousness by Erich Neumann
[9] The Hero with a Thousand Faces by Joseph Campbell
[10] Essence of the Upanishads by Eknath Easwaran