Get AI summaries of any video or article — Sign up free
Obsidian - Sync Vaults Between PCs with Github thumbnail

Obsidian - Sync Vaults Between PCs with Github

Josh Plunkett·
5 min read

Based on Josh Plunkett's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.

TL;DR

Obsidian vaults are plain folders and files, so syncing can be done with tools beyond Obsidian Sync.

Briefing

Keeping an Obsidian vault in sync across multiple PCs doesn’t require an always-on cloud service. Because Obsidian stores everything as a plain folder of files (including a hidden .obsidian settings folder), the vault can be backed up and synchronized using standard file-sync tools—most notably GitHub—so changes made on one machine can be pulled onto another.

The core tradeoff is straightforward: Obsidian Sync is the official, paid, subscription-based option (listed as $10/month or $96/year) and is positioned as the recommended path, especially for Apple users. But the practical appeal of Obsidian is that its local, file-based design lets users choose their own sync method. The transcript walks through several alternatives—USB drives, Google Drive, OneDrive, and SyncThing—then focuses on GitHub as a preferred approach for “live” syncing and version history.

GitHub works here because it functions as a code repository: it tracks changes, supports collaborative editing, and maintains a commit history. In practice, the vault folder is turned into a GitHub repository using GitHub Desktop. Once the repository is published, changes can be pushed from one PC to GitHub and then fetched/cloned onto another PC. The result is a near-real-time workflow where notes, folders, and content appear on the second machine as GitHub updates are pulled down.

A major advantage highlighted is auditability. GitHub’s commit history lets users inspect what changed in a specific note, including line-level differences (with removed content shown in red and additions in green). If something breaks—like a custom CSS tweak—users can browse prior commits and roll back to earlier versions.

The transcript also emphasizes the operational rule that prevents headaches: avoid opening the same vault on two computers at the same time. GitHub can handle merges, but Obsidian’s constantly changing state (such as active tabs and other session-like settings stored in the .obsidian folder) makes conflicts more likely. The recommended routine is to work on one PC, push changes to GitHub, close Obsidian, then switch to the other PC, fetch updates, open Obsidian, work, push again, and close.

Setup is presented step-by-step: install GitHub Desktop (or use git as an alternative), create or select an Obsidian vault folder, initialize it as a Git repository (adding a .git and .git attributes plus a README if desired), publish the repository (public or private), then use GitHub Desktop’s commit/push and fetch/clone features on the second PC. The workflow is framed as free for public repositories (with a stated storage allowance) and paid for private repositories, with the transcript noting private vaults may matter for copyrighted material.

Overall, GitHub-based syncing is positioned as a flexible, version-controlled alternative to Obsidian Sync—one that leverages Obsidian’s file-based vault structure while trading away the “set-and-forget” simplicity of an official sync service.

Cornell Notes

Obsidian vaults are just folders of files, including a hidden .obsidian settings directory, which makes them compatible with many sync methods. GitHub can be used as a synchronization and backup layer by turning a vault folder into a Git repository, pushing changes from one PC, and fetching them on another. GitHub’s commit history adds a practical benefit: users can see exactly what changed in a note and revert to earlier versions when something breaks. To avoid merge conflicts, the workflow should keep Obsidian closed on one machine before switching to another—don’t edit the same vault simultaneously on two PCs. The approach can be free for public repos and paid for private repos, which may matter for copyrighted content.

Why does Obsidian’s storage format make GitHub syncing possible?

Obsidian vaults are plain folders and files. Inside the vault folder sits a hidden .obsidian directory that stores settings (including things like active tab state and installed plugins/themes), while the rest of the vault contains the note content and folder structure. Because everything is file-based, GitHub can track changes to those files just like it tracks code changes in a repository.

What is the basic GitHub Desktop workflow for syncing a vault between two PCs?

On PC A, install GitHub Desktop, add a local repository pointing to the vault folder, and let GitHub Desktop initialize it as a Git repo if it isn’t one yet. Commit changes (with a message/description) and push to the remote repository on GitHub. On PC B, clone or fetch the repository, open the vault in Obsidian, work, then commit and push back to GitHub. The key actions are commit/push on the working machine and fetch/clone on the other.

What does GitHub’s commit history add beyond syncing?

GitHub provides an edit trail for every push. The transcript highlights viewing commit details for a specific file (e.g., custom CSS), where additions and removals are shown with color-coded diffs (red for removed lines, green for added lines). This makes it easier to diagnose what broke and to restore earlier versions by browsing prior commits.

Why does the transcript warn against opening the same vault on two computers at once?

Obsidian keeps updating files while it’s open, including session-like metadata in .obsidian. If two PCs edit and push conflicting versions of the same files simultaneously, Git may require merges and conflict resolution. The transcript recommends a disciplined sequence: push and close Obsidian on PC A before fetching and opening on PC B, minimizing conflicts.

What alternatives to GitHub are mentioned, and how do they differ?

The transcript lists USB-based syncing (copy the vault via a removable drive), cloud folder syncing via Google Drive or OneDrive, and SyncThing as a free sync option (noting it works well for PC to Android and is unlikely to work for iPhones). GitHub is singled out as a preferred method because it adds version history and structured change tracking, not just file mirroring.

When might private GitHub repositories matter for vault syncing?

Private repositories can be important when vaults contain copyrighted material that shouldn’t be shared publicly. The transcript notes paying for private storage to keep certain vaults private, especially when they include content copied from official books.

Review Questions

  1. If a vault is edited on two PCs at the same time, what kinds of conflicts are most likely and why?
  2. How does turning an Obsidian vault folder into a Git repository change what GitHub can do with the vault?
  3. What specific GitHub features (beyond syncing) help with troubleshooting broken notes or custom CSS?

Key Points

  1. 1

    Obsidian vaults are plain folders and files, so syncing can be done with tools beyond Obsidian Sync.

  2. 2

    GitHub-based syncing works by converting the vault folder into a Git repository and using GitHub Desktop to commit/push and fetch/clone.

  3. 3

    GitHub’s commit history provides line-level change tracking, making it easier to diagnose and roll back broken notes.

  4. 4

    To reduce merge conflicts, avoid editing the same vault simultaneously on two PCs; push and close Obsidian before switching machines.

  5. 5

    GitHub Desktop simplifies setup: initialize a local repository, publish it, then use commit/push on one machine and fetch/clone on another.

  6. 6

    Public repositories can be free, while private repositories require a subscription—use private repos when vault content shouldn’t be public.

Highlights

Obsidian vaults sync well with GitHub because the vault is literally a folder of files, including a hidden .obsidian settings directory.
GitHub commit history functions like a version control log for notes—diffs show what was removed and what was added.
The safest workflow is single-machine editing: push changes and close Obsidian before opening the vault on another PC.
GitHub Desktop can initialize a vault as a repository automatically when the selected folder isn’t already a Git repo.
GitHub can serve as both a backup and a synchronization mechanism, not just a collaboration platform.

Topics

  • Obsidian Sync
  • GitHub Desktop
  • Vault Synchronization
  • Version History
  • Merge Conflicts

Mentioned