# Obsidian plugin

Save a browser tab into your Obsidian vault as a vector PDF and a Markdown note.

**Scan a browser tab into the vault**, a command in Obsidian, lists the tabs open in your browser,
scans the one you pick, and puts two files in a folder of your vault: the page as a PDF whose text
you can still select and search, and a note with the page's text as Markdown and the PDF embedded
under its properties. It is in Obsidian's community plugins as
[Page Scanner](https://community.obsidian.md/plugins/page-scanner), for Obsidian on a desktop.

The capture is done by the web extension in your browser, as it is for [the command line](https://docs.pagescanner.app/cli):
the plugin runs the `page-scanner` command, which asks the extension for the page.

## Set it up

1. Install [the web extension](https://docs.pagescanner.app/extension) 1.3.0 or newer, in Chrome, Edge, Brave, Arc or
   Vivaldi.

2. Install [Node.js](https://nodejs.org) 22 or newer, then the command, in a terminal:

   ```bash
   npm install -g @page-scanner/cli
   ```

3. In Obsidian, open **Settings**, **Community plugins**, **Browse**, search for **Page Scanner**,
   install it and enable it.

4. Open the plugin's settings. The four steps at the top say what is done and check again every
   few seconds: Node.js, the command (with the npm line and a **Copy** button while it is
   missing), **Install helper**, and **Connect** in the extension's settings, under
   [Local agents](https://docs.pagescanner.app/extension/local-agents).

Obsidian cannot run the command with its own runtime, so the plugin looks for it beside each Node
on the computer (Homebrew's, `/usr/local/bin`, Volta's, fnm's default, or your shell's) and runs it
on the Node it was installed for. **Node**, under **Advanced** in the plugin's settings, names one
by hand.

## Scan a tab

Run **Scan a browser tab into the vault** from the command palette, or press the scan button in the
ribbon. The picker lists the open tabs with the one in front of your browser first; type to filter
by title or address, and press Enter.

In the folder set in the settings (`Page Scanner` by default), the scan leaves two files named
after the page's title:

- `Markdown - Wikipedia.pdf`, the whole page.
- `Markdown - Wikipedia.md`, the note:

  ```text
  ---
  title: "Markdown - Wikipedia"
  source: "https://en.wikipedia.org/wiki/Markdown"
  captured: 2026-09-25T11:02:41.000Z
  ---

  ![[Page Scanner/Markdown - Wikipedia.pdf]]

  # Markdown

  Markdown is a lightweight markup language …
  ```

A name the vault already holds gets ` 2`, ` 3` added, and characters a file name or a link cannot
hold (`[ ] | # ^ : / \`) become dashes. The note opens once it is saved, unless **Open the note** is
off.

## Settings

| Setting       | Choices                                                            |
| ------------- | ------------------------------------------------------------------ |
| Folder        | a vault folder; the vault's root when empty                        |
| Page size     | A4, US Letter, one long page                                       |
| Theme         | as in Page Scanner's settings, the browser's, light, dark          |
| Page width    | as in Page Scanner's settings, the window's, A4, US Letter         |
| Hide clutter  | as in Page Scanner's settings, all of it, none of it               |
| Open the note | on by default                                                      |
| Node          | a Node.js 22 or newer to use; found on the computer when empty     |
| Browser       | a connected browser's label or ID, when more than one is connected |

"As in Page Scanner's settings" leaves the choice to the extension's
[Capture settings](https://docs.pagescanner.app/extension/settings#capture). The editor's own output (a crop, marks, a frame, a stamp,
PDF/A) is not applied to a scan from Obsidian.

## What it does outside the vault

It runs the command you installed as a separate process. The command writes each scan into the
system's temporary folder before the plugin moves it into the vault, and keeps its pairing in
`~/.page-scanner/`, where **Install helper** also puts the small launcher your browser starts.
Nothing goes over the network beyond this computer: the command listens on `127.0.0.1` only, and
the page is captured by your own browser. The plugin's source is public, at
[sbd530/page-scanner-obsidian](https://github.com/sbd530/page-scanner-obsidian).
