Link Target Switch

approvedunreviewed

by Remko H. Pape

Choose per click whether web links open in the Web viewer or your browser. Hold a key to switch, or flip the default from the status bar.

Updated todayMIT

Link Target Switch

Choose per click whether a web link opens in Obsidian's built-in Web viewer or in your system browser, without going through the right-click menu.

With the Web viewer core plugin, every external link opens inside Obsidian. That is great for quick reading, but sometimes you want the real browser (logins, extensions, downloads). Until now the only way was right-click, then "Open in default browser". This plugin makes that a single click.

How it works

ActionResult
Click a web linkOpens in your default target
Alt + click (or Shift, configurable)Opens in the other target
Click 🔗 Web viewer / 🔗 Browser in the status barFlips the default
Ctrl / Cmd + clickLeft to Obsidian's normal behaviour

Works in Reading view, Live Preview, Source mode, canvas cards and hover previews, for [text](https://...) links, <https://...> links and bare URLs.

Commands

All commands can be bound to a hotkey in Settings → Hotkeys.

  • Toggle default link target (Web viewer / browser)
  • Open link under cursor in browser
  • Open link under cursor in Web viewer
  • Open current Web viewer page in browser: hands the page you are reading in the Web viewer over to your browser.

Settings

  • Default target: Web viewer or Browser.
  • Switch key: Alt / Option or Shift.
  • Show in status bar: show or hide the status bar toggle.

Requirements

  • Obsidian 1.8.0 or newer, desktop only.
  • The Web viewer core plugin enabled (Settings → Core plugins). If it is off, links fall back to your browser.

Installation

From Community plugins

Settings → Community plugins → Browse → search for Link Target Switch → Install → Enable.

Manually

  1. Download main.js and manifest.json from the latest release.
  2. Put them in <your vault>/.obsidian/plugins/link-target-switch/.
  3. Reload Obsidian and enable Link Target Switch under Settings → Community plugins.

Privacy

The plugin makes no network requests of its own and collects no data. It only decides where a link you click is opened.

AI disclosure

This plugin was created with the help of AI (Claude by Anthropic). The code was generated by AI based on my idea and requirements, and has been reviewed and tested by me before release. Issues and pull requests are welcome.

License

MIT

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.