Joplin implements the SQLite Full Text Search (FTS4) extension. It means the content of all the notes is indexed in real time and search queries return results very fast. Both Simple FTS Queries and Full-Text Index Queries are supported. See below for the list of supported queries:
One caveat of SQLite FTS is that it does not support languages which do not use Latin word boundaries (spaces, tabs, punctuation). To solve this issue, Joplin has a custom search mode, that does not use FTS, but still has all of its features (multi term search, filters, etc.). One of its drawbacks is that it can get slow on larger note collections. Also, the sorting of the results will be less accurate, as the ranking algorithm (BM25) is, for now, only implemented for FTS. Finally, in this mode there are no restrictions on using the
* wildcard (
ast*rix all work). This search mode is currently enabled if one of the following languages are detected:
|Single word||Returns all the notes that contain this term.||For example, searching for |
|Multiple word||Returns all the notes that contain all these words, but not necessarily next to each other.|
|Phrase||Add double quotes to return the notes that contain exactly this phrase.|
|Prefix||Add a wildcard to return all the notes that contain a term with a specified prefix.|
|Switch to basic search||One drawback of Full Text Search is that it ignores most non-alphabetical characters. However in some cases you might want to search for this too. To do that, you can use basic search. You switch to this mode by prefixing your search with a slash |
You can also use search filters to further restrict the search.
|-||If placed before a text term, it excludes the notes that contain that term. You can also place it before a filter to negate it.|
|any:||Return notes that satisfy any/all of the required conditions. |
|Restrict your search to just the title or the body field.|
|tag:||Restrict the search to the notes with the specified tags.|
|notebook:||Restrict the search to the specified notebook(s).|
|Searches for notes created/updated on dates specified using YYYYMMDD format. You can also search relative to the current day, week, month, or year.|
|type:||Restrict the search to either notes or todos.|
|iscompleted:||Restrict the search to either completed or uncompleted todos.|
|Filter by location|
|resource:||Filter by attachment MIME type|
|sourceurl:||Filter by source URL|
|id:||Filter by note ID|
Note: In the CLI client you have to escape the query using
-- when using negated filters.Eg.
:search -- "-tag:tag1".
The filters are implicitly connected by and/or connectives depending on the following rules:
- By default, all filters are connected by "AND".
- To override this default behaviour, use the
anyfilter, in which case the search terms will be connected by "OR" instead.
- There's an exception for the
notebookfilters which are connected by "OR". The reason being that no note can be in multiple notebooks at once.
Incorrect search filters are interpreted as a phrase search, e.g. misspelled
nootebook:Example or non-existing
Notes are sorted by "relevance". Currently it means the notes that contain the requested terms the most times are on top. For queries with multiple terms, it also matters how close to each other the terms are. This is a bit experimental so if you notice a search query that returns unexpected results, please report it in the forum, providing as many details as possible to replicate the issue.
In the desktop application, press Ctrl+P or Cmd+P and type a note title or part of its content to jump to it. Or type # followed by a tag name, or @ followed by a notebook name.