A fully open source & end-to-end encrypted note taking alternative to Evernote.
title: Find & replace pageTitle: Find and replace text inside a note in Notesnook description: Search inside the note you're editing with Ctrl+F, match case, whole words or a regular expression, and replace one match or all of them at once. keywords: - notesnook find and replace - search inside a note - notesnook regex search schema: howto
How do I find and replace text in a note?
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.
Find text in the note
:::tabs key:platform == Desktop/Web
- Click into the note, then press
Ctrl+F. You can also click the search button in the editor's top bar. - Type what you're looking for. Matches are highlighted as you type and the counter beside the field shows which match you're on, for example
3/12. - Press
Enterfor the next match,Shift+Enterfor the previous one — or use the{{nextMatch}}and{{previousMatch}}buttons. - Press
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
- Tap the
⋮menu in the editor header. - Tap the magnifying glass in the row at the top of the menu.
- The find box opens as a sheet at the bottom of the screen. Type your search term; matches are highlighted and counted the same way.
- Use
{{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.
Narrow the search with match case, whole word or regex
The three matching options are folded away until you ask for them.
- Click the
{{expand}}chevron inside the search field. - Turn on any combination of:
{{matchCase}}—{{note}}no longer matchesnote.{{matchWholeWord}}—catmatchescatbut notcatalogue.{{enableRegex}}— your search term is treated as a regular expression instead of literal text.
- The result count updates immediately.
::: 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.
:::
Replace one match or all of them
:::tabs key:platform == Desktop/Web
- Press
Ctrl+Alt+F, or pressCtrl+Fand then click{{toggleReplace}}. - Type the search term in the first field and the replacement in the second.
- Click
{{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. - Click
{{replaceAll}}to replace every match in the note in one step.
== Mobile
- Tap the
⋮menu, then the magnifying glass. - In the sheet, tap
{{toggleReplace}}to reveal the replacement field. - Use
{{replace}}for the current match, or{{replaceAll}}for every match in the note.
:::
::: 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.
:::
Why is there no replace field on this note?
{{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.
Find & replace versus searching all your notes
| 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 |
Related pages
- Editor toolbar — every formatting tool and how to customize the toolbar
- Searching and navigating — finding notes across your whole account
- Tabs & panes — the editor top bar, side panes and focus mode
- Headings — collapsing sections, and how search reveals them
- Keyboard shortcuts — the full list for desktop and web