How To Use Syncthing On Android
The real super poweruser command line way
Syncthing is excellent- just keep some folders in sync, full privacy, just works. I love it.
It even works on android!!! Full file sync on the phone- doesn't get much better. With graphene, this is like the full privacy perfect functionality kind of solution. What is there not to like?
Well it so happens that syncthing for android is a bit of a bolt-on kind of thing and I wasn't really able to get it to run exactly like I wanted.
Even worse, it got discontinued! There is a successor app but it's also not exactly working the way I wanted. It was good enough for sure, but I never knew exactly when it would sync, even though there are settings.
So I was using more and more of termux on my phone, first as a toy, then as a tool, and now it's becoming more and more of my phone with calendar and tasks and mail site access and imagemagick (to edit pictures before printing them in the Drogeriemarkt photo machine) and now even claude code is in there for sysadmin stuff.
So I noticed that you could install syncthing in termux and it just worked exactly like on linux- reliable, easy, like on unix. It was perfect.
It wasn't that great for my battery though, so I realized that could be fixed using Tasker, an android scheduling app.
I know Tasker's not open source and costs a whopping five bucks, but after trying every other solution I became a bit pragmatic about that.
So I dropped the fiver.
With tasker, I set up an event that would trigger whenever the phone is charging. I have this crazy large data plan, but if I didn't, I could also insist it's connected to WiFi, or even a specific WiFi. And then it runs a script called start-syncthing.sh, by selecting 'Tasker' and then 'Termux Command' in the setup. And there is a stop-syncthing.sh for the inverse. And I threw in a backup-camera.sh script as well for good measure, to one-way backup the camera directory with rsync.
Welp- tasker just works. Plug phone in, syncthing. Unplug phone, no syncthing. Easy as pie. I spent more time than I'd like to admit having 'http://localhost:8384' open and watching the web frontend disconnect and connect as I plugged and unplugged. It was mesmerizing. ;)
So there I have it. Perfectly reliable syncthing on android. And likely for a long time, no app store app to maintain for anyone.