Cross-vault internal links

Use case or problem

Quickly link between notes in open vaults.

Proposed solution

For all open vaults, enable cross-vault use of [[internal links]]. The internal links from one vault to another would be active and clickable as long as the “destination” vault is open. If that vault is closed, then the link would not be clickable. If the destination vault is closed perhaps Obsidian could display a tooltip message such as Vault <valult> is not available, or something like that.

I realize having a feature that would “break” if the right combination of vaults is not open is suboptimal, but the current work-arounds of having to set up obsidian:// URLs is also sub-optimal. The feature I’m suggesting utilizes Obsidian’s rapid linking feature, and I assume Obsidian can be aware of the open vaults in the environment. Correct me if I’m wrong.

Current workaround (optional)

Use obsidian:// file path or Advanced URI (plugin) links.

Related feature requests (optional)

I didn’t find any, but I wouldn’t be surprised if others more knowledgable or adept than me have debated this feature at length.

1 Like

Can you say more about why using Obsidian URLs is sub-optimal for you?

Is it because you are missing fuzzy auto-completion when making the new link? Or anything else?

  1. Getting an Obsidian URL from A to paste in B is more steps than typing [[note name...]] and letting Obsidian do auto-find/complete.
  2. Linking to #headings and ^blocks with URLs is even more complex.
  3. If the destination note moves, the URL can break.
  4. Obsidian tries to suggest strings within Obsidian URLs as “unlinked mentions” – this is partially avoidable, but not optimal.
  5. Using the Advanced URI plugin with the UUID feature (i.e., the plugin finds the UUID in frontmatter) is a bit easier, and avoids the “note moved” issue, but still extra time spent flipping back and forth between vaults to grab and paste the URL.

For many reasons that I cannot change, I work between at least two vaults that are always open. “Internal linking” between them would be wonderful.

2 Likes

I don’t think that will ever be possible.
Obsidian exists within its vault. Anything outside is just files folders etc - even if they are sometimes vaults.
Only option would be nesting the vaults and doing the linking from the new top vault, which would be able to see all the files in both vaults. However, I suspect that, even if that were feasible for you, that your usage would cause problems.

1 Like

Well, maybe. Maybe not. It’s software. The software can be aware of what’s in the open vaults.

And, perhaps, feasibility is a developer consideration. No harm at all in wishing.

I always feel “feature requests” in a user forum is a way for users to explain their wishes. Assessing what the developer can or cannot do is well beyond our pay grades, maybe. I would love to hear what licat or silver think.

Anyway, I mentioned above that I’m fully aware that if the vault at the other end of an internal link is closed, then the internal link would be broken. I accept that shortcoming.

3 Likes

(please don’t tag the devs.)

I agree it is just software and wishes are welcome. There could be possible solutions. For #1, for example, it might be interesting to have a fuzzy-matching URL generator that can read all your open vaults, and make it easier to create a URL by searching.

For #3 I can’t see this being avoided. I certainly wouldn’t want anything I do in one vault to automatically change any aspect of another vault without my explicit consent. Especially if the vault was not open. And like you already pointed out, it could be inconsistent depending on whether it is open or not.

#4 Someone else flagged this as a feature request, and I personally think it could be considered a bug. I hope that gets fixed, or as an option to make it not suggest or change those links.

WARNING: This is still WORK IN PROGRESS
IDEAS ARE WELCOME

@RoyRogers made me thinking.

INFO:
In my example I have to Vaults called u_sc and u_mc.
The obsidian-links do even work if the vault is not open!

This is not the solution but a helper using the Community-Plugin Templater:

  1. Install and configure the Plugin Templater
  2. Create a new note like this in the template folder
[<%tp.system.prompt('Link Title')%>](obsidian://open?vault=<%tp.system.suggester(["u_sc", "u_mc"], ["u_sc", "u_mc"])%>&file=<%tp.system.prompt('Note Name')%>.md)
  1. Use the template
    • open Command-Prompt
    • open Insert Templates Modal
    • name of the note
  2. Enter the information into the prompts:
    • Name of the note (this could be changed to be inserted from the clipboard with tp.system.clipboard())
    • Title of the link (I guess you could use the selected text - but I did not yet get the interface of tp.obsidian.? to work properly
    • select the right vault
  3. Check and test the inserted Markdown-link with the obsidian//:open function

:ballot_box: TODO:
Improve the Templater code as suggested

:ballot_box: TODO:
Dynamically generate a list of vaults

:ballot_box: TODO:
I am still wondering how you could control the order of the prompts. (Issue

:question: NOTE:
I still am not sure if an Obsidian Vault may still be sitting in an Obsidian vault itself…
that might open up new options!

1 Like

Some other workaround for that is using symlinks:

(Windows) mklink /d path\to\link\folder path\to\source\folder

So that you can have reference to some folder inside another vault. Or multiple vaults.

And you can use links to linked folder the same way you would use usual folder with files. No need to change anything

1 Like

The symlink is a good idea. This is great because it utilizes the file system feature. It is maybe not as portable if you look on cross-plattform like Windows to Mac or iOS and Android.

Does anyone have experimented with this?

We (part time or full time) Windows users might get an interesting option with Windows 11 and next generation “Windows Subsystem Linux” (WSL)

See Run Linux GUI apps with WSL | Microsoft Learn

This would be great for using the linux file system that is the same base file concept as in Mac (maybe even Android)

1 Like