How do I search Obsidian notes by created or modified date in obsidian-mcp-server?
I use obsidian-mcp-server with Claude and want to ask something like "Create a new note with all of the tasks I added to notes in the last two weeks". The original search tools didn't let me filter by file creation or modification date. Is there a way to search notes by ctime/mtime in the current version?
Originally asked on GitHub: https://github.com/cyanheads/obsidian-mcp-server/issues/8
4 answers
Fixed. This shipped in the v3.0 rewrite; the latest release is v3.1.7 on npm (
obsidian-mcp-server). The maintainer confirmed thatobsidian_search_notesnow has two query modes that filter on file dates.To find notes modified in the last 14 days, use Dataview DQL mode with a query like:
TABLE file.mtime FROM "" WHERE file.mtime > date(today) - dur("14 days")For the "tasks added in the last two weeks" workflow, JSONLogic mode lets you write predicates against
stat.mtime(modified time) andstat.ctime(created time).During the rewrite the maintainer also added
obsidian_global_search, a text/regex search across the whole vault that supports filtering by modification date, restricting to a directory (recursively), pagination (page,pageSize), and capping matches per file (maxMatchesPerFile). Each result includes file path, filename, ctime, mtime, and match snippets.If the new query shape doesn't cover your use case, the maintainer asked that the issue be reopened and said they'd dig in.
General advice: if you are still on a v2.x install, upgrade to v3.x so
obsidian_search_notesis available.Did this work for you?What a GitHub user tried on GitHub (Outcome unclear)
Reported the desired workflow: ask Claude to gather tasks added to notes in the last two weeks into a new summary note; no date-filtered search existed at the time.
Source: https://github.com/cyanheads/obsidian-mcp-server/issues/8 (opens external site)
Did this work for you?What @cyanheads tried on GitHub (Partly worked)
The maintainer added
obsidian_global_searchon themcp-ts-template-refactorbranch, supporting text/regex search, modification-date filtering, directory restriction, and pagination.Did this work for you?What @cyanheads tried on GitHub (Worked)
The maintainer delivered the feature in the v3.0 rewrite:
obsidian_search_notessupports Dataview DQL and JSONLogic filters on mtime/ctime, with v3.1.7 as the latest release.Did this work for you?
Related questions
- Fix 'SSL certificate verification failed' (DEPTH_ZERO_SELF_SIGNED_CERT) in obsidian-mcp-server on Windows
- How do I fix obsidian-mcp-server initialize timeout with Claude for Desktop on Windows?
- How can I tell if obsidian_append_to_note created a file or appended to an existing one?
- Fix 'Unsupported protocol version: 2025-03-26' in obsidian-mcp-server
- obsidian-mcp-server: -32005 Insufficient permissions with Authentik/Keycloak OIDC?