Hi everybody roamy :),

I am attempting to combine org-protocol with org-roam. My chrome bookmark contains: javascript:location.href = 'org-protocol://roam-ref?template=p&ref=' + encodeURIComponent(location.href) + '&title=' + encodeURIComponent(document.title).

Does anybody has a nice template where I could include the selected text too?

Also, I would like the frame to pop up or at least be brought to the front (at the moment, the creation of the capturing happens in the background, so I have to move to Emacs to finish the capture). Thanks so much for you input!

1 Answer 1


Two steps in my case:

  1. You use add &body.. to the bookmarklet, this is from the current documentation of org-roam:
javascript:location.href = 'org-protocol://roam-ref?template=r&ref='
          + encodeURIComponent(location.href)
          + '&title='
          + encodeURIComponent(document.title)
          + '&body='
          + encodeURIComponent(window.getSelection())
  1. Change the capture template to include the body, in my case I added \n\n${body}:
   '(("r" "ref" plain "%?" :target
      (file+head "${slug}.org" "#+title: ${title}\n\n${body}")
      :unnarrowed t))))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.