Skip to main content
Glama

zotero-native-mcp

An MCP server that reads and writes your Zotero 10+ library, entirely offline.

Zotero 10+ npm CI License: MIT DOI

Connect Zotero to Claude, Claude Code, Cursor, or any Model Context Protocol client. Your assistant can search your library, read PDF full text, create collections, add references, and attach PDFs from your disk.

Every operation runs against the Zotero application on 127.0.0.1. No zotero.org account. No web API key. No Zotero plugin. No cloud round trip.

Claude files a paper into a Zotero collection, then renames 290 tags across the library, all through zotero-native-mcp

Why this exists

Zotero 10 added write support to its built-in local API. Before that, every Zotero MCP server had to work around a read-only local endpoint, either by routing writes through api.zotero.org (slow, needs an API key, needs your library synced to the cloud) or by shipping a separate Zotero plugin you had to install and keep up to date.

This server uses the native capability directly. Nothing to install inside Zotero, no credentials to manage, and reads land in 8–60 ms because nothing touches the network.

Criterion

Web API servers

Plugin-based servers

zotero-native-mcp

Works offline

❌

✅

✅

Needs a zotero.org API key

✅ required

❌

❌

Needs a Zotero plugin (.xpi)

❌

✅ required

❌

Create collections

✅

✅

✅

Attach local PDFs

⚠️ via cloud

✅

✅

Typical read latency

500–1500 ms

<50 ms

8–60 ms

Related MCP server: zotero-mcp

Requirements

  • Zotero 10 or newer, running. This is a hard floor, not a preference: writing through the local API did not exist before Zotero 10. On Zotero 7–9 the read tools work and every write fails.

  • Zotero → Settings → Advanced → enable "Allow other applications on this computer to communicate with Zotero".

  • Node.js 22 or newer. Node 20 reached end of life in April 2026.

Tested on

Everything below is a statement of evidence, not of intent. Other platforms and clients are expected to work. The server is portable TypeScript talking to 127.0.0.1, with nothing platform-specific by design. But they have not been verified, and this table is the honest extent of it.

Component

Verified against

Operating system

macOS 26.6 (Apple Silicon), Windows 11 Pro build 26200 (x64) and Ubuntu 24.04 LTS (x86_64), all three against a real Zotero

Zotero

10.0.1

Node.js

26.8, 22.23 and 24.16 respectively; 22, 24 and 26 in CI

MCP client

Claude Code 2.1, on macOS and Windows

Libraries

Personal and group, all 28 tools exercised in both

CI runs the unit and mock-protocol suites across a matrix of Linux, macOS and Windows × Node 22, 24 and 26, so portability of the code itself is covered on all three platforms. What no runner can cover is the conversation with a real Zotero, since none is installed there. That part was done by hand: scripts/coverage.mjs reaches all 28 tools on all three operating systems, against a live library.

Not yet verified. Intel Macs; Claude Code on Linux, where only the scripts were run; Claude Desktop, Cursor and other MCP clients anywhere.

If you run it somewhere not on this list, a report either way is welcome, those are the most useful issues this project can receive right now.

Back up your library first

WARNING

This server can modify and delete items in your Zotero library. Back it up before you start, and keep backing it up.

Deleting is reversible by default: zotero_delete_items and zotero_delete_collection move things to Zotero's trash, where you can restore them from the Zotero window or with zotero_restore_items. But Zotero empties that trash automatically after 30 days, and both tools take a permanent: true that erases outright, no undo, attachment files removed from disk, nothing in the API able to bring them back. zotero_empty_trash does the same to everything already in the trash.

These tools are driven by an assistant interpreting instructions in natural language, which can misread which item you meant.

To back up: quit Zotero, then copy your whole data directory, ~/Zotero on macOS and Linux, %USERPROFILE%\Zotero on Windows, or whatever Settings → Advanced → Files and Folders reports. It holds zotero.sqlite and the storage folder with every attachment. Zotero's own guidance is at zotero.org/support/zotero_data.

Syncing to zotero.org is not a backup: a deletion syncs too.

This software is provided as is, without warranty of any kind, and its authors accept no liability for data loss. See LICENSE.

Quick start

claude mcp add --scope user zotero-native-mcp -- npx -y zotero-native-mcp
{
  "mcpServers": {
    "zotero-native-mcp": {
      "command": "npx",
      "args": ["-y", "zotero-native-mcp"]
    }
  }
}

--scope user registers it for every project. Without it, claude mcp add defaults to the local scope, which ties the server to the one directory you ran the command in, open anything else and the tools are simply absent.

No environment variables are needed. Start a new session, then ask your assistant to run zotero_status to confirm the connection.

The first time a tool writes, Zotero shows a dialog asking whether to allow it. Choose "Always Allow" so you are not asked again.

Documentation

Document

What it covers

📚 Tutorial

New here? Ten minutes from install to filing a paper with its PDF.

🔧 How-to guides

Attach PDFs · Group libraries · Migrate from another Zotero MCP · Recover a deletion · Troubleshooting

📖 Reference

All 28 tools, parameters, outputs, limits, environment variables.

💡 Explanation

Architecture · Linked vs imported attachments · How authorization works

🛠 Contributing

Development setup, the 73-test suite, and exercising every tool against a live Zotero.

Tools at a glance

Collections: list_collections get_collection create_collection update_collection delete_collection restore_collection

Items: search_items get_item get_item_children create_items update_item delete_items restore_items add_items_to_collection remove_items_from_collection get_item_fulltext export_items

Trash: list_trash empty_trash (and the restore_* tools above)

Attachments: attach_file get_attachment_path

Discovery: list_tags list_saved_searches run_saved_search

System: status authorize list_libraries get_item_type_fields

All names are prefixed zotero_. See the reference for full signatures.

Prior art

This project is not a fork. It was written from scratch once Zotero 10 made native local writes possible, but it stands on the shoulders of earlier work that solved the same problem under tighter constraints:

If you need Zotero 7/8/9 support, semantic or vector search, or writes to a library you only have cloud access to, then those projects remain the right choice.

Contributing

Issues and pull requests are welcome. CI must pass on Linux, macOS and Windows across Node 22, 24 and 26.

See CONTRIBUTING for the development setup, the test suite, and the scripts that exercise every tool against a live Zotero.

License

MIT © David Sosa-Trejo


Keywords: Zotero MCP server · Model Context Protocol · Zotero Claude integration · Zotero local API · offline reference manager automation · Zotero AI assistant · BibTeX export · academic research tooling · Claude Code Zotero · Cursor Zotero

Available Tools

28 tools
zotero_add_items_to_collectionAdd items to a collectionA
Idempotent

File existing items into a collection, keeping every collection they already belong to. An item in Zotero can sit in any number of collections, so this adds rather than moves. Items already in the collection are reported as unchanged and cost no write.

Inputs: itemKeys (required), collectionKey (required), groupId. Returns: added, collectionKey, alreadyPresent

zotero_attach_fileAttach a local fileA

Attach a file from disk to a Zotero item, or add it as a standalone attachment. mode="linked" (default) records the path only: instant for any file size, but the file must stay put and the attachment does not sync to zotero.org. mode="imported" copies the file into Zotero's storage, so it syncs and survives the original being moved. Group libraries accept only "imported", since a local path means nothing to other members. filePath must be absolute. Pass parentItemKey to hang the file off an existing reference; omit it for a standalone attachment, optionally filed into collections.

Inputs: filePath (required), mode, tags, title, +3 more. Returns: mode, bytes, filePath, uploaded, +3 more

zotero_authorizeRequest Zotero write accessA
Idempotent

Request a local API key so write tools (creating collections, items, and attachments) can run. This raises a modal dialog inside Zotero on the user's screen with three choices: "Allow" issues a single-use key, "Always Allow" issues a persistent one, and "Deny" refuses. Tell the user to expect the dialog, and to pick "Always Allow" for a session that will perform several writes. The key is stored locally and reused; write tools also re-authorize on their own when a single-use key is spent, so calling this manually is only needed to grant access up front. Calling it when a key is already stored reuses that key and shows no dialog.

Inputs: force. Returns: message, authorized, persistent, alreadyHeld

zotero_create_collectionCreate collectionsA

Create one or more collections, optionally nested under an existing collection. Up to 50 per call. Creating a nested tree takes one call per level, since a child needs its parent's key. Requires write access; zotero_authorize runs automatically if none has been granted.

Inputs: collections (required), groupId. Returns: created, failures, libraryVersion

zotero_create_itemsCreate itemsA

Create up to 50 items in one call. Set collections on an item to file it into collections as it is created, which is cheaper than creating it and moving it afterwards. Notes and attachments are created by setting parentItem. To attach a file from disk use zotero_attach_file instead, which handles the whole attachment protocol. Check the returned failures array: Zotero validates each item independently, so some can succeed while others fail.

Inputs: items (required), groupId. Returns: created, failures, libraryVersion

zotero_delete_collectionDelete collectionsA
DestructiveIdempotent

Move collections to Zotero's trash, which is reversible and the default. The items inside are never deleted either way: they stay in the library and in any other collection they belong to. Subcollections follow their parent. Pass permanent: true only on an explicit request from the user, to erase the collections outright with no way back. Note that a trashed collection cannot be listed through the local API, so record the key returned here if it may need restoring.

Inputs: collectionKeys (required), groupId, permanent. Returns: erased, trashed, notFound, permanent, +1 more

zotero_delete_itemsDelete itemsA
DestructiveIdempotent

Move up to 50 items to Zotero's trash, where the user can restore them from the Zotero window or with zotero_restore_items. This is the default and it is reversible. Trashed items keep their attachments and files; Zotero empties the trash automatically after 30 days by default. Pass permanent: true only when the user has explicitly asked for an irreversible delete: that erases the items outright, takes their child notes and attachments with them, removes attachment files from disk, and cannot be undone by anything.

Inputs: itemKeys (required), groupId, permanent. Returns: erased, trashed, notFound, permanent, +2 more

zotero_empty_trashEmpty the trashA
DestructiveIdempotent

Permanently erase every item in the trash. This is irreversible and removes attachment files from disk. As an interlock against emptying a trash the caller has not looked at, expectedCount must equal the number of items actually in it: call zotero_list_trash first and pass its totalResults. If the two disagree the call is refused and nothing is deleted. Only use this when the user has explicitly asked to empty the trash.

Inputs: expectedCount (required), groupId. Returns: erased, libraryVersion

zotero_export_itemsExport citationsA
Read-onlyIdempotent

Export items in a citation format. Use format "bibtex", "biblatex", "ris", "csljson", "csv" or "tei" for a machine-readable export, or "bib" to render a formatted bibliography in a citation style (set style, e.g. "apa", "chicago-note-bibliography", "ieee"). Returns the export as text.

Inputs: itemKeys (required), style, format, locale, +1 more. Returns: format, output, itemCount, skippedKeys

zotero_get_attachment_pathGet an attachment file pathA
Read-onlyIdempotent

Resolve an attachment to its absolute path on this machine, so the file can be opened and read directly. Works for both linked and imported attachments. Passing a regular item key returns the paths of all of its file attachments. Use this to read a PDF whose text Zotero has not indexed.

Inputs: itemKey (required), groupId. Returns: attachments

zotero_get_collectionGet a collectionA
Read-onlyIdempotent

Fetch one collection by key, including its name, parent collection, item count and current version. The version is what zotero_update_collection and zotero_delete_collection use for conflict detection.

Inputs: collectionKey (required), groupId, verbose. Returns: collection

zotero_get_itemGet an itemA
Read-onlyIdempotent

Fetch one item by key with all of its metadata. Set includeChildren to also return its notes and attachments, which is the quickest way to find the attachment key needed to read a PDF or its full text.

Inputs: itemKey (required), groupId, verbose, includeChildren. Returns: item, children

zotero_get_item_childrenGet item childrenA
Read-onlyIdempotent

List the child notes, attachments and annotations of an item. Attachment children carry the linkMode and filename needed by zotero_get_attachment_path and zotero_get_item_fulltext.

Inputs: itemKey (required), limit, start, groupId, +1 more. Returns: start, hasMore, children, returned, +2 more

zotero_get_item_fulltextGet attachment full textA
Read-onlyIdempotent

Return the indexed full text of an attachment. Passing a regular item key works too: its attachments are searched and the first one with indexed text is used. Text comes from Zotero's own index, so it is available only for attachments Zotero has indexed. Long documents can be truncated with maxCharacters.

Inputs: itemKey (required), groupId, maxCharacters. Returns: content, truncated, totalPages, indexedPages, +2 more

zotero_get_item_type_fieldsDescribe an item typeA
Read-onlyIdempotent

List the valid field names and creator types for a Zotero item type, or list every item type when itemType is omitted. Call this before zotero_create_items with an unfamiliar item type: Zotero rejects a write outright if it carries a field the type does not define.

Inputs: itemType. Returns: fields, itemType, itemTypes, creatorTypes

zotero_list_collectionsList collectionsA
Read-onlyIdempotent

List collections in a library. scope="all" returns every collection flat (each carrying its parentCollection key, so the full tree can be reconstructed in one call), "top" returns only root-level collections, and "children" returns the direct subcollections of parentKey. Collection keys returned here are what zotero_create_items, zotero_add_items_to_collection and zotero_search_items take.

Inputs: limit, scope, start, groupId, +2 more. Returns: start, hasMore, returned, nextStart, +2 more

zotero_list_librariesList librariesA
Read-onlyIdempotent

List the personal library and every group library available locally. Use this to get the groupId that other tools take when the target is a group library rather than "My Library".

Inputs: no named parameters. Returns: groups, personalLibrary

zotero_list_saved_searchesList saved searchesA
Read-onlyIdempotent

List the saved searches defined in the library, with their conditions. Run one with zotero_run_saved_search. Note that the local API can actually execute saved searches, which the zotero.org web API cannot.

Inputs: limit, start, groupId, verbose. Returns: start, hasMore, returned, searches, +2 more

zotero_list_tagsList tagsA
Read-onlyIdempotent

List tags in the library, optionally only those used within one collection or matching a search. Useful for discovering how a library is organized before filtering zotero_search_items by tag.

Inputs: q, limit, qmode, start, +2 more. Returns: tags, start, hasMore, returned, +2 more

zotero_list_trashList the trashA
Read-onlyIdempotent

List the items currently in Zotero's trash, which are the ones zotero_restore_items can bring back. Note that trashed collections do not appear here: Zotero's local API offers no way to enumerate them, so a trashed collection can only be restored by key or from the Zotero window.

Inputs: limit, start, groupId, verbose. Returns: items, start, hasMore, returned, +2 more

zotero_remove_items_from_collectionRemove items from a collectionA
Idempotent

Remove items from one collection. The items stay in the library and in any other collection they belong to; nothing is deleted. Items that were not in the collection are reported as unchanged.

Inputs: itemKeys (required), collectionKey (required), groupId. Returns: removed, notPresent, collectionKey

zotero_restore_collectionRestore collections from the trashA
Idempotent

Bring collections back out of Zotero's trash, undoing a non-permanent zotero_delete_collection. You must know the key: Zotero's local API cannot list trashed collections, so there is no way to discover them from here, the user can see them in the Zotero window's trash. A collection erased permanently cannot be restored at all.

Inputs: collectionKeys (required), groupId. Returns: notFound, restored

zotero_restore_itemsRestore items from the trashA
Idempotent

Bring items back out of Zotero's trash, undoing a non-permanent zotero_delete_items. The items return to the collections they were in. Only works while they are still in the trash: nothing can recover an item that was erased permanently or that Zotero has already purged after its 30-day retention.

Inputs: itemKeys (required), groupId. Returns: notFound, restored, wereNotInTrash

zotero_search_itemsSearch itemsA
Read-onlyIdempotent

Search the local Zotero library. q runs Zotero's quicksearch: qmode "titleCreatorYear" (default) matches titles, creators and years, while "everything" also matches attachment full text and notes. Filters combine: pass collectionKey to search inside one collection, itemType to restrict by type ("-attachment" excludes a type), tag to filter by tag. Omit q to browse. Returns flattened item metadata; use zotero_get_item for one item in full.

Inputs: q, tag, sort, limit, +10 more. Returns: items, start, hasMore, returned, +2 more

zotero_statusZotero connection statusA
Read-onlyIdempotent

Check that the local Zotero instance is running and reachable, and report its version, schema version, instance ID, and whether write access has been granted yet. Call this first when any other tool reports a connection or authorization problem.

Inputs: no named parameters. Returns: appName, baseUrl, serverId, connected, +6 more

zotero_update_collectionRename or move a collectionA
Idempotent

Rename a collection and/or move it under a different parent. Pass parentCollectionKey=null to move a collection to the root of the library. The current version is fetched automatically unless expectedVersion is given, in which case the write fails with a conflict if the collection changed in the meantime.

Inputs: collectionKey (required), name, groupId, expectedVersion, +1 more. Returns: updated, collectionKey, libraryVersion

zotero_update_itemUpdate an itemA
Idempotent

Patch fields on an existing item. Only the fields passed in fields change; everything else is left alone. Array fields are replaced wholesale, so to change collection membership prefer zotero_add_items_to_collection / zotero_remove_items_from_collection, which merge instead of overwriting. The current version is read automatically unless expectedVersion is supplied.

Inputs: fields (required), itemKey (required), groupId, expectedVersion. Returns: itemKey, updated, libraryVersion

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 28 tools

    Disambiguation4/5

    Each tool targets a distinct resource/action, and the descriptions clearly separate collection, item, attachment, trash, and search workflows. A few read paths overlap (e.g. get_item with includeChildren vs. get_item_children; get_item_fulltext vs. get_attachment_path), but the boundaries are explained well enough that misselection is unlikely.

    Naming Consistency5/5

    All tools follow a consistent zotero_ + verb + noun pattern, with uniform CRUD verbs (create, update, delete, restore) and predictable list_ vs. get_ usage. One-off verbs like attach, export, empty, and run also fit the convention, making the set very predictable.

    Tool Count4/5

    28 tools is above the typical well-scoped range, but the count reflects the breadth of the Zotero local API: collections, items, attachments, trash, search, tags, saved searches, export, and authorization. A few tools could theoretically be folded together, but none are redundant or filler.

    Completeness5/5

    The set covers the full lifecycle for collections and items, including reversible deletion, restore, permanent deletion, trash listing, and emptying. It also includes attachments, full-text access, search, tags, saved searches, export, and authorization/status, leaving no obvious dead ends for real Zotero workflows.

    Maintenance

    ActivityMaintained
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Read-only MCP server that lets Claude or any MCP client search and retrieve metadata, notes, full text, citations, and BibTeX from your local Zotero library via its built-in API.
      11
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Read-only MCP server for your local Zotero library. Browse collections, inspect paper metadata, and extract full-text from PDFs via FastMCP tools.
      4
      MIT
    • F
      license
      Not graded
      quality
      C
      maintenance
      MCP server for interacting with a Zotero library via the local API. Enables searching, retrieving, creating, updating, and deleting Zotero items, managing collections and tags, and generating citations.
      -