Syncthing as a service

đź›  Syncthing Setup Guide with whoami

  1. Check installation
    Make sure Syncthing is installed correctly:

    syncthing --version
    

    This confirms the binary is available.

  2. Enable the service at boot and start immediately
    Syncthing ships with a systemd unit file named syncthing@.service.
    You can automatically insert your current username with whoami:

    sudo systemctl enable syncthing@$(whoami).service
    sudo systemctl start syncthing@$(whoami).service
    
  3. Verify service status

    systemctl status syncthing@$(whoami).service
    

    Look for “active (running)” in the output.
    If it’s not running, check logs with:

    journalctl -u syncthing@$(whoami).service
    
  4. Firewall considerations

    • Syncthing uses 22000/tcp for sync traffic.
    • It also uses 21027/udp for local discovery.

    With ufw:

    sudo ufw allow 22000/tcp
    sudo ufw allow 21027/udp
    

    The commands shown are for ufw. If you use another firewall, adjust accordingly.