Wireguard + syncthing (from F-Droid) work fine. Triggering it when the phone is on the charger makes it very easy to sync things from a computer to the phone, while next to the computer.
It absolutely does not work fine. Keeping 2x the size of my database in free space on my phone to let backups work it's no solution at all, which is why I stopped doing it. (The backup creates two files - current and previous, and Syncthing can't remove complete files to another location, so you need an actually rather difficult to write script to do it).
I recently vibe-coded a crappy Windows Go GUI to grab files off my phone via rclone & sshd4a and then optionally delete them, but it's a very manual process since sshd4a has to be running on the phone before I initiate the pull.
Syncthing is just open source Dropbox, self hosted.
It's entire purpose is "make two folders identical".
It's very good at that: so good that I frequently wish it did other things - i.e. if it had some notion of minimum seeding levels so it would destage files off a device provided they were replicated elsewhere (e.g. automatically clearing old photos off your phone would be a good use of it).