Setting Up Obsidian on Ubuntu and Syncing with Git & Android (Step-by-Step)

Published: (January 10, 2026 at 03:32 PM EST)
3 min read
Source: Dev.to

Source: Dev.to

Why Obsidian + Git?

  • Markdown‑based, future‑proof notes
  • Full version history (unlike cloud sync tools)
  • Private repositories = full control over data
  • Works across Linux, Windows, and Android

Step 1: Install Obsidian on Ubuntu

Download the .deb package from the official site:
https://obsidian.md/download

Install using gdebi (it resolves dependencies automatically):

sudo apt-get update
sudo apt-get install gdebi

Open the downloaded .deb file with GDebi Package Installer and install Obsidian.

Step 2: Create a Private GitHub Repository

  1. Go to GitHub and create a new repository.
  2. Set it to Private.
  3. Do not initialize with a README (Obsidian will populate it).

Step 3: Clone the Repository Using SSH (Desktop)

cd ~/Documents
git clone git@github.com:DasDNS/Obsidian_Notes.git

You should see output similar to:

Cloning into 'Obsidian_Notes'...
Receiving objects: 100% (4/4), done.

Verify the remote:

cd Obsidian_Notes
git remote -v

Output:

origin  git@github.com:DasDNS/Obsidian_Notes.git (fetch)
origin  git@github.com:DasDNS/Obsidian_Notes.git (push)

Step 4: Open the Vault in Obsidian (Ubuntu)

  1. Open Obsidian.
  2. Click Open folder as vault.
  3. Select Obsidian_Notes.
  4. Start creating notes.

Step 5: Install & Configure Obsidian Git Plugin (Desktop)

  1. Go to Settings → Community Plugins.
  2. Disable Safe Mode.
  3. Install Obsidian Git and enable the plugin.

Recommended settings

  • Auto commit on interval
  • Auto pull on startup
  • (Optional) Commit message template

Your notes will now automatically commit and sync.

Step 6: Why Android Needs HTTPS (Important)

  • Obsidian Git on Android does NOT support SSH.
  • It does support HTTPS with a Personal Access Token (PAT).

We keep SSH on the desktop and create an HTTPS‑compatible copy of the vault for Android.

Step 7: Create an HTTPS‑Compatible Copy (Desktop)

Duplicate the vault:

cp -r ~/Documents/Obsidian_Notes ~/Documents/Obsidian_Notes_HTTPS
cd ~/Documents/Obsidian_Notes_HTTPS

Change the remote from SSH to HTTPS:

git remote set-url origin https://github.com/DasDNS/Obsidian_Notes.git

Verify:

git remote -v

Output:

origin  https://github.com/DasDNS/Obsidian_Notes.git (fetch)
origin  https://github.com/DasDNS/Obsidian_Notes.git (push)

The repository is now Android‑compatible.

Step 8: Copy the Vault to Android

  1. Connect the phone via USB and enable File Transfer (MTP).
  2. Copy the entire folder, including:
    • .git/
    • .obsidian/
    • All markdown files

Recommended location on the device:

Internal Storage / Obsidian

Note: Copy the folder itself, not just its contents.

Step 9: Install Obsidian on Android

  • Install Obsidian from the Play Store.
  • Open the app and select Open existing folder.
  • Choose the copied Obsidian folder.

Step 10: Git Sync on Android (Access Token Required)

  1. Go to Settings → Community Plugins and enable Obsidian Git.
  2. Open the Command Palette and run Obsidian Git: Pull.

You’ll be prompted for:

  • Username → your GitHub username
  • PasswordPersonal Access Token (PAT)

SSH keys do not work on Android; the token is mandatory.

After entering the token, Obsidian Git will pull updates, commit changes, and push back to GitHub.

Final Result

  • Ubuntu → SSH Git (secure & fast)
  • Android → HTTPS Git (token‑based)
  • Same private repository
  • Full version history
  • Offline‑first notes

Final Thoughts

This setup gives you:

  • Full control over your data
  • No paid sync service
  • A workflow that scales from student notes to research archives

If you’re serious about long‑term note‑taking, Obsidian + Git is worth the effort.

References

  • Obsidian + GitLab Setup (Andrew Wegner) – a detailed walkthrough that informed the desktop Git steps.
  • Obsidian Android Syncing via GitHub (Reddit) – community discussion about syncing Obsidian on Android using GitHub and personal access tokens.
Back to Blog

Related posts

Read more »

Hello, Newbie Here.

Hi! I'm falling back into the realm of S.T.E.M. I enjoy learning about energy systems, science, technology, engineering, and math as well. One of the projects I...