Which type of links should I use?

Hi. This may be a silly question but I would like to get your opinions.
I noticed that Obsidian allows choosing Wikilinks over Markdown links for links and images. Which ones are ‘better’? By ‘better’ I mean easier to use, allowing more things to do, more compatible with other apps.
Which type do you use?

*** I do not import any notes to Obsidian. I am starting with the creation of my vault from the ground and would like to use the correct and best way for linking!

Thanks!

3 Likes

It mostly depends on what else you plan to use these note files with. Other apps and services outside of Obsidian may not recognize the wikilink format—for interoperability, if and only if you’re using some incompatible app/service, you need to use conventional markdown links.

3 Likes

I recently started my own Obhsidain journey and had the same question. At the moment I’m using [[wikilinks]] but am considering changing to markdown links for interoperability. In my case, I have no idea what / how I will use my notes in future so might as well keep them as ‘standardised’ as possible (that’s my thinking anyway).

Whilst on the topic is there an easy way to convert all [[wikilinks]] to markdown links?

AFK at the moment, but the Markdown Importer plugin (enable it in Preferences → Core Plugins, then look for the button on the app ribbon) might provide a conversion for this. Edit: I was wrong.

Otherwise any mass find-and-replace feature with RegEx support would do. (E.g., VSCode, I think.)

Also AFK but thanks I’ll definitely check it out.

Update: I was wrong, it isn’t in the Markdown Importer ;<

There is a third-party plugin for this, though. I have not tried it: https://github.com/agathauy/wikilinks-to-mdlinks-obsidian

1 Like

Thanks for following up. I see that it only converts one link at a time and that converting all links is something planned for the future.

I think I’ll try my hand at putting together a Keyboard Maestro automation for this and share it on the forum.

Update: So I started to look at doing this, and quickly got myself thinking if the relative file path also then needs to be added into the markdown link :thinking:.

I then tried out the 3rd party plugin that you mentioned and saw that it doesn’t add a file path (and it seems that Obsidian doesn’t need it), but it does add the .md suffix. So with that in mind I tried switching the “Use [[Wikilinks]]” toggle in the settings off and saw that it doesn’t add this suffix.

So quite a few questions floating around my head atm:

  1. Should the markdown link have a relative path? Surely if not the links won’t work in other software?
  2. .md suffix or not? And again which will work best with other software?

At the moment I’m tempted to stick with [[Wikilinks]] and if I ever do need to change for a specific reason, I could parse all of my notes and replace them with the correct syntax (although I’m still not sure how that woudl be done with the file path).

This is what I’d do.

To answer your questions, you’re right that relative should be more robust and that some apps will require .md. But, this is going to depend on the app.

Best to switch if and when the time comes, and feel safe knowing you’ll have the option!

Definitely!

In the meantime I took a look at the settings for automatic link creation and there are 3 options when it comes to “New link format”:

  • shortest when possible
  • relative
  • absolute

Funny enough when you choose either of the last 2 Obsidian doesn’t automatically pipe the link with just the file name so you get something rather unfriedly to look at e.g. [[daily/2020-11-28]].

With this in mind I am wondering if the easiest & most robust method is just to have all notes in the root of the Vault. That way the absolute path would just be the file name (without .md).

I guess that would be the easiest thing to do too