# Link Obsidian with AdvancedURI Plugin

**URL:** https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691
**Category:** Discussion & Help
**Created:** [February 19, 2022, 9:10am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691 "2022-02-19T09:10:44Z")
**Posts on this page:** 20
**Page:** 3

<div class="post-metadata">

### Author: ![bchend](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/b/dbc845/32.png) [@bchend](https://discourse.hookproductivity.com/u/bchend)
#### Post date: [March 3, 2022, 10:30pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/41 "2022-03-03T22:30:26Z")

</div>

Thank you!

> [@Vinzent03](#):
>
> fileuri=file%3A%2F%2F%2F%2Fhome%2Fvinzent%2Fdesktop%2Fcoding%2Fobsidian-testing%2Fexample%2520file.md

It seems the fileuri has 4 “///”:  
file:////home/…

If it has three “/”, it works.

---

<div class="post-metadata">

### Author: ![Vinzent03](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/vinzent03/32/2126_2.png) [@Vinzent03](https://discourse.hookproductivity.com/u/Vinzent03)
#### Post date: [March 3, 2022, 10:40pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/42 "2022-03-03T22:40:40Z")

</div>

I thought I have to add another slash, because absolute paths on unix start with a slash, but [wikipedia](https://www.wikiwand.com/en/File_URI_scheme#/Unix) has only 3 too.

Released a new version.

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 4, 2022, 2:05am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/43 "2022-03-04T02:05:25Z")

</div>

I’m delighted to see all the progress.

> [@bchend](#):
>
> In the x-callback-url, it is “my+notes+10”. Is it possible that it is encoded as “my%20notes%2010”?

The default Obsidian method of getting the title doesn’t include “+”; but of course it’s currently using the clipboard rather than x-callback-url or other API.

I guess if Obsidian is encoding titles with “+” for space there’s a bug in the Obsidian code. Per [URL encoding the space character: + or %20? - Stack Overflow](https://stackoverflow.com/questions/1634271/url-encoding-the-space-character-or-20)

> The reserved characters are different for each part.
> 
> For HTTP URLs, a space in a path fragment part has to be encoded to “%20” (not, absolutely not “+”), while the “+” character in the path fragment part can be left unencoded.
> 
> Now in the query part, spaces may be encoded to either “+” (for backwards compatibility: do not try to search for it in the URI standard) or “%20” while the “+” character (as a result of this ambiguity) has to be escaped to “%2B”.  
> […]  
> **should have `%20` before the `?` and `+` after.**

of course, we’re not dealing with HTTP URLs, but the principles are the same

Because Hook use x-callback-url with the AdvancedURI, and x-callback-url is asynchronous it would be awkward for Hook to correct the title received by the plugin by comparing the result with the path information (it would have to do that outside the integration script, or Hook could fall back on the Obsidian method which utilizes the clipboard, but relying on clipboard here is awkward).

---

<div class="post-metadata">

### Author: ![bchend](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/b/dbc845/32.png) [@bchend](https://discourse.hookproductivity.com/u/bchend)
#### Post date: [March 4, 2022, 2:17am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/44 "2022-03-04T02:17:14Z")

</div>

Tested the fileuri in the new release. Works great!

Thank you!

---

<div class="post-metadata">

### Author: ![Vinzent03](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/vinzent03/32/2126_2.png) [@Vinzent03](https://discourse.hookproductivity.com/u/Vinzent03)
#### Post date: [March 4, 2022, 1:30pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/45 "2022-03-04T13:30:32Z")

</div>

Is there now a problem or not? As you said, encoding the title as query parameter with `+` is valid. Since I pass the title as query parameter, I think everything is okay?

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 4, 2022, 5:44pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/46 "2022-03-04T17:44:54Z")

</div>

Yes we shall decode it 🙂

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 9, 2022, 12:35am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/47 "2022-03-09T00:35:25Z")

</div>

@Vinzent03 , Version: 1.20.0 of the Advanced URI no longer has an ID tag, and it is not robust with file moves. When using a URI after a file has moved, Obsidian creates a new file in the old location and opens it.

We still find it helpful to be able to get the path from the Advanced URI that you provide.

---

<div class="post-metadata">

### Author: ![Vinzent03](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/vinzent03/32/2126_2.png) [@Vinzent03](https://discourse.hookproductivity.com/u/Vinzent03)
#### Post date: [March 9, 2022, 6:37am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/48 "2022-03-09T06:37:53Z")

</div>

I think I never mentioned it, but you have to enable `Use UID instead of file paths` in the settings. Because it modifies the file to save the uid, it’s not enabled by default.

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 9, 2022, 7:10am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/49 "2022-03-09T07:10:09Z")

</div>

> [@Vinzent03](#):
>
> Use UID instead of file paths

got it. Thank you very much!

---

<div class="post-metadata">

### Author: ![Wen](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/w/f9ae1b/32.png) [@Wen](https://discourse.hookproductivity.com/u/Wen)
#### Post date: [March 9, 2022, 12:05pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/50 "2022-03-09T12:05:16Z")

</div>

Is there an estimated date on when this would be integrated with Hook? I frequently link items with Obsidian notes, so it would be great if this can be supported soon. 🙂

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 9, 2022, 4:13pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/51 "2022-03-09T16:13:22Z")

</div>

> [@Vinzent03](#):
>
> I think I never mentioned it, but you have to enable `Use UID instead of file paths` in the settings. Because it modifies the file to save the uid, it’s not enabled by default.

It should go into 3.4.3 which we will release within a couple of days if all goes well. The release is focused on Obsidian support.

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [March 9, 2022, 8:05pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/52 "2022-03-09T20:05:26Z")

</div>

@Vinzent03 . So @bchend and I both tested. What we found was: if there is no ID in the file, the `Copy Advanced URI` in Obsidian UI works fine (it appends the URI to the URL). but the next time, it fails (regardless of whether we move the file).

Bi Ling says the plugin used to work. The change happened after your last modification. If it works for you, maybe it’s a Mac vs. PC/Linux issue. We’re using macOS of course.

---

<div class="post-metadata">

### Author: ![Vinzent03](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/vinzent03/32/2126_2.png) [@Vinzent03](https://discourse.hookproductivity.com/u/Vinzent03)
#### Post date: [March 9, 2022, 8:25pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/53 "2022-03-09T20:25:35Z")

</div>

If you call the command via the ui

> it appends the URI to the URL

you mean `uid` instead of `URI` right?

As always, only 4 extra chars should have fixed it. I released a new version.

---

<div class="post-metadata">

### Author: ![bchend](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/b/dbc845/32.png) [@bchend](https://discourse.hookproductivity.com/u/bchend)
#### Post date: [March 9, 2022, 8:57pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/54 "2022-03-09T20:57:16Z")

</div>

> [@Vinzent03](#):
>
> you mean `uid` instead of `URI` right?

You are right. Sorry for the typo.

Tested the new release. Works great!

Thank you very much for your quick action!

---

<div class="post-metadata">

### Author: ![jebeaudoin](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/jebeaudoin/32/2392_2.png) [@jebeaudoin](https://discourse.hookproductivity.com/u/jebeaudoin)
#### Post date: [August 10, 2022, 3:52pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/55 "2022-08-10T15:52:20Z")

</div>

I’ll cross-post this over on the Obsidian community, but I just hit an unexpected quirk and wanted to document it in case others using both Hook and Obsidian experience the same problem.

Set up -  
Obsidian: Version 0.15.9 (Installer 0.15.6) with the AdvancedURI plugin installed  
Mac OX: macOS Monterey Version 12.5  
Hook Method: Using the Advanced URI integration between Hook and OBsidian as described in [Using Hook with Obsidian – Hook](https://hookproductivity.com/help/integration/using-hook-with-obsidian/#:~:text=Using%20the%20%E2%80%9CAdvanced%20URI%E2%80%9D%20integration%20between%20Hook%20and%20Obsidian)

After doing some housecleaning on my Obsidian vault, during which I had enabled some other plugins, moved folders around and renamed the vault, the AdvancedURI hook no longer opened Obsidian to the correct note in Obsidian when invoked. I spent two hours testing out hypotheses before realizing that a plugin I was using ([Home Page](https://github.com/mirnovov/obsidian-homepage)) was interfering with the process.

The moral of the story – any of Obsidian’s plugins may interfere with the expected results of the AdvancedURI hook method, so if you are troubleshooting, start there!

In the meantime I’ve turned off the Home Page plugin, but I do wonder if this is the kind of thing one files a ticket on in Github. If so, would you file it on @Vinzent03’s plugin, or the Home Page plugin?

Cheers, and thanks for these very helpful applications and plugins, and for working together to achieve great outcomes!

Jack Beaudoin (no relation to @LucB I don’t think)

---

<div class="post-metadata">

### Author: ![psidnell](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/psidnell/32/1575_2.png) [@psidnell](https://discourse.hookproductivity.com/u/psidnell)
#### Post date: [August 24, 2022, 4:37pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/56 "2022-08-24T16:37:57Z")

</div>

The advanced URI plugin embeds the vault name in the URL:

`obsidian://advanced-uri?vault=MyVault&uid=8165c0db-4e2d-4007-9ffa-6e19c99e1eaf`

Does updating the vault name to match the notes new home in your URLs mend the link?

---

<div class="post-metadata">

### Author: ![darkwing](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/darkwing/32/2697_2.png) [@darkwing](https://discourse.hookproductivity.com/u/darkwing)
#### Post date: [May 26, 2023, 6:10am UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/57 "2023-05-26T06:10:18Z")

</div>

@LucB - Is there a way to “Hook to new” Obsidian note with multiple vault support? i.e. Either create a separate Obsidian item in the list, or have it bring up a selection box to select from available Obsidian vaults?

---

<div class="post-metadata">

### Author: ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)
#### Post date: [May 26, 2023, 2:54pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/58 "2023-05-26T14:54:47Z")

</div>

Welcome to the Hookmark Forum , @darkwing. I don’t think the integration options don’t currently provide that . There’s

> **[Using Hookmark with Obsidian – Hookmark](https://hookproductivity.com/help/integration/using-hook-with-obsidian/)**
>
> This document assumes you are using Hookmark 3.5 or newer, and Obsidian O.14.16 or newer. If you are still using Hookmark 3.4.3, please refer to Using Hook 3.4.3 with Obsidian.
> 
> Obsidian is an Electron-based note-taking app that treats links as first...

But given how configurable Hookmark and Obsidian is, there might be a way. The `Hook to New` script for any app can be modified, per [Scripts Tab – Hookmark](https://hookproductivity.com/help/preferences/script-editor/).

---

<div class="post-metadata">

### Author: ![technovangelist](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/technovangelist/32/1323_2.png) [@technovangelist](https://discourse.hookproductivity.com/u/technovangelist)
#### Post date: [July 13, 2023, 7:53pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/59 "2023-07-13T19:53:00Z")

</div>

Are there any changes in how this works recently. It’s been a while since I tried, but now every time I hook a file then choose new obsidian, i get a new file, rather than opening the old one. so each file will be title, title 1, title 2, title 3, etc.

I am using the Advanced URI plugin, with Use UID instead of paths enabled. I have disabled every other plugin. I am using the Hookmark that is part of Setapp (though I bought Hook a few years back as well). So I wondered if the bundleid is different in the script and the defaults command. Tried setting those accordingly. Both configs don’t work. and both Hooks don’t work. I have restarted both Hookmark and Obsidian just in case. Even restarted the mac. Nothing seems to work. Each test I have tried I have just one instance of hook running (again, I have the Hook I bought, and the Setapp Hook), but noticed this before installing the Setapp version today.

What else can I try.

I see that when I create new from a web page in Arc and Chrome, or from a note in the Notes app on Mac, the frontmatter does not get created in Obsidian. But if I hook the note in Obsidian, the frontmatter does get created.

---

<div class="post-metadata">

### Author: ![bchend](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/b/dbc845/32.png) [@bchend](https://discourse.hookproductivity.com/u/bchend)
#### Post date: [July 13, 2023, 8:25pm UTC](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691/60 "2023-07-13T20:25:43Z")

</div>

Welcome back, @technovangelist .

There is no change for Obsidian recently.

Could you please elaborate more on this issue? Do you mean you tried to do “Hook to New Obsidian”? If you can post some screenshots, that would be very helpful.

Thank you

> [@technovangelist](#):
>
> but now every time I hook a file then choose new obsidian, i get a new file, rather than opening the old one. so each file will be title, title 1, title 2, title 3, etc.

[Previous page](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691.md?page=2)

[Next page](https://discourse.hookproductivity.com/t/link-obsidian-with-advanceduri-plugin/4691.md?page=4)
