docs/help/contents/rich-text-editor/search-and-replace.md
Press Ctrl+F while the editor is focused to search the note you're writing, or Ctrl+Alt+F to open the same box with a replace field. On macOS use Command instead of Ctrl. This searches inside the open note only — to search across every note, see searching and navigating.
Ctrl+F. You can also click the search button in the editor's top bar.3/12.Enter for the next match, Shift+Enter for the previous one — or use the {{nextMatch}} and {{previousMatch}} buttons.Escape, or click {{close}}, when you're done.::: tip Start from a selection
If you select some text before pressing Ctrl+F, that text is put into the search field for you.
== Mobile
⋮ menu in the editor header.{{nextMatch}} and {{previousMatch}} to step through the results, and {{close}} to dismiss the sheet.:::
Notesnook scrolls to each match as you move through them, and reveals matches that are hidden inside a collapsed heading, a collapsed callout or a collapsed outline list item.
The three matching options are folded away until you ask for them.
{{expand}} chevron inside the search field.{{matchCase}} — {{note}} no longer matches note.{{matchWholeWord}} — cat matches cat but not catalogue.{{enableRegex}} — your search term is treated as a regular expression instead of literal text.::: info About regular expressions
With {{enableRegex}} off, regular expression characters are escaped so the term is matched literally. With it on, the term is compiled as a JavaScript regular expression with the g, u and m flags, so patterns like \d+ or ^Chapter work and ^/$ anchor to each line. . does not match across line breaks. An expression that doesn't compile returns no matches.
:::
Ctrl+Alt+F, or press Ctrl+F and then click {{toggleReplace}}.{{replace}} to replace the match you're on — Notesnook then jumps to the next match, so you can work through the note by clicking {{replace}} repeatedly.{{replaceAll}} to replace every match in the note in one step.::: warning Replace all cannot be undone from the search box
{{replaceAll}} rewrites every match at once. If it wasn't what you wanted, close the search box and press Ctrl+Z (Command+Z) in the editor to undo, or restore an earlier version from note history.
:::
{{toggleReplace}}, {{replace}} and {{replaceAll}} only appear when the note can be edited. On a note in read-only mode you still get the full find experience — searching, match counting, and the matching options — but nothing can be rewritten until you turn read-only off.
| You want to… | Use |
|---|---|
| Find a word in the note you're editing | Ctrl+F inside the editor |
| Find notes by their content or title | Ctrl+F outside the editor, which opens search |
| Jump to a heading in a long note | The table of contents pane |