Facebook explains how it can collect info about you even if you never post on Facebook
https://www.cnbc.com/2018/04/16/facebook-collects-data-even-when-youre-not-on-facebook.html
Facebook's product management director David Baser just wrote a blog post explaining when Facebook and its partners collect your personal information and when it's shared.
It also reiterates how it's able to gather information on people who don't use Facebook.