These instructions are if you want to be connected to the internet but still pretty private.
The ideal is to install LineageOS. If that's not possible on your device, then when setting up your device, don't create a Google Account and don't use the Google Apps or Google Play Store or cloud storage.
To sync your files with your computer, including pictures taken, videos taken, music, podcasts, and books, use Syncthing. Alternatively, you could sync them manually by plugging in your phone with a wire, but that's less convenient because you have to do it manually, whereas Syncthing continually syncs your files automatically.
For apps, you can install F-Droid and get a lot of open source apps from there. This prevents the common problem of using apps that track you and are ad-supported.
For web browsing, there are many options available through F-Droid. I like the Fennec web browser (a version of Firefox).
For syncing contacts and calendar, one option is to use Decsync. On the computer, I use Thunderbird + Radicale + Syncthing, and on the phone, DecsyncCC + Syncthing. This is somewhat limited in that the contacts and calendar don't instantly sync on the phone, so sometimes you have to manually click the sync button on the phone if you want them synced faster. Actually in Thunderbird I only use the calendar, not contacts, because contacts just need to be accessed on the phone, but I still have contacts synced with Radicale for the sake of a backup. If you have the habit of entering them on the phone, then this is OK.
Another option is to set up a Radicale server on the computer, and connect to it on the phone by installing the DAVx⁵ app; however, that takes more effort to set up and is intended for computers (servers) that are always running. It may do weird things and give error messages if you regularly turn off your computer so that your phone can't connect to the server. With Decsync, it converts the calendars and contacts to files which sync through Syncthing whenever both of them are running.
This process will not fully protect you. To be 100% protected you have to live without a cell phone. But it's a compromise that minimizes, rather than eliminates, Surveillance Capitalism.