Shopify MCP
Connects to the Shopify Admin GraphQL API for managing products, collections, orders, customers, draft orders, inventory, locations, metafields, metaobjects, files, and redirects.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Shopify MCPshow me orders from last week"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
███████╗██╗ ██╗ ██████╗ ██████╗ ██╗███████╗██╗ ██╗ ███╗ ███╗ ██████╗██████╗
██╔════╝██║ ██║██╔═══██╗██╔══██╗██║██╔════╝╚██╗ ██╔╝ ████╗ ████║██╔════╝██╔══██╗
███████╗███████║██║ ██║██████╔╝██║█████╗ ╚████╔╝ ██╔████╔██║██║ ██████╔╝
╚════██║██╔══██║██║ ██║██╔═══╝ ██║██╔══╝ ╚██╔╝ ██║╚██╔╝██║██║ ██╔═══╝
███████║██║ ██║╚██████╔╝██║ ██║██║ ██║ ██║ ╚═╝ ██║╚██████╗██║
╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝╚═╝ Shopify MCP
A Model Context Protocol (MCP) server that connects agents to the Shopify Admin GraphQL API. Use it to browse, edit, and clean up store data via a curated set of tools.
npm: shopify-mcp
binary: shopify-mcp
Highlights
CRUD for products, collections, orders, and customers
Draft orders for quotes, manual orders, and B2B pricing
Inventory and location lookups for stock workflows
Metafields for custom data
Metaobject entry creation and lookup for existing definitions
URL redirects management
OAuth login flow with local token caching
Bulk product cleanup utilities
Fail-closed read-only mode for audit and QA agents
Related MCP server: Kockatoos Shopify MCP Server
Prerequisites
Node.js 18+
A Shopify custom app (OAuth or Admin API token)
Local setup (this repo)
Use this when you want to run the MCP server from this local checkout instead of a remote deployment.
Install dependencies and build:
npm install
npm run buildCreate local env config:
cp .env.example .envSet at least:
MYSHOPIFY_DOMAIN=your-store.myshopify.comEither:
SHOPIFY_CLIENT_ID=...andSHOPIFY_CLIENT_SECRET=...for a Dev Dashboard app owned by the store's organization; orSHOPIFY_ACCESS_TOKEN=shpat_xxxfor a static/manual token
REMOTE_MCP=false
Start local MCP (stdio):
npm run start:localstart:local uses stdio mode. Remote mode is only enabled with --remote or REMOTE_MCP=true.
Read-only mode
Start a capability-restricted server for QA, audit, and reporting agents:
shopify-mcp --read-only --domain=<YOUR_SHOP>.myshopify.com
# or
SHOPIFY_MCP_READ_ONLY=true npm run start:localRead-only mode exposes only a reviewed allowlist of lookup and reporting tools.
All mutating, mixed read/write, file-upload, and unknown future tools are hidden.
The allowlist is fail-closed, so a newly added tool does not appear in a
read-only instance until it is explicitly reviewed. get-status reports the
effective access mode, whether the boundary is enforced, and whether write
tools are exposed.
Use a least-privilege Shopify token as well when one is available. The server boundary is designed to remain useful when a deployment must temporarily share an existing token: agents connected to the read-only MCP instance cannot call the hidden mutation tools.
Install + run
Client credentials (same Shopify organization)
For a Dev Dashboard app installed on a store owned by the same Shopify organization, configure:
MYSHOPIFY_DOMAIN=your-store.myshopify.com
SHOPIFY_CLIENT_ID=your-client-id
SHOPIFY_CLIENT_SECRET=your-client-secretNo callback URL or browser consent is required. The MCP obtains Shopify's
24-hour access token at startup, caches it per permanent MyShopify domain in
~/.shopify-mcp/tokens.json, and renews it automatically before expiry.
Cached tokens include the client ID so a token created by a different app is
never silently reused after an app cutover.
Shopify does not allow this grant for public or custom-distribution apps on stores owned by another organization; use the authorization-code flow below for those apps.
Authorization-code OAuth
Create a custom app and copy Client ID and Client Secret.
In App setup, set App URL and Allowed redirection URLs to:
http://localhost:3456/callbackStart the OAuth flow:
npx shopify-mcp --oauth --domain=your-store.myshopify.com --clientId=xxx --clientSecret=yyyTokens are stored at ~/.shopify-mcp/tokens.json. After that, start the server with just the domain:
npx shopify-mcp --domain=your-store.myshopify.comOptional: override scopes with --scopes or SHOPIFY_SCOPES.
Access token (manual)
Create a custom app in Shopify
Enable Admin API scopes:
read_products,write_productsread_customers,write_customersread_orders,write_ordersread_draft_orders,write_draft_ordersread_inventory,write_inventoryread_locationsread_content,write_contentread_files,write_files
Install the app and copy the Admin API access token
Run:
shopify-mcp --accessToken=<YOUR_ACCESS_TOKEN> --domain=<YOUR_SHOP>.myshopify.comMCP client setup
Claude Desktop (local repo build)
Build first (npm run build), then point Claude Desktop at this repo's built entrypoint:
{
"mcpServers": {
"shopify-local": {
"command": "node",
"args": [
"/absolute/path/to/shopify-mcp/dist/index.js",
"--domain",
"your-store.myshopify.com"
],
"env": {
"SHOPIFY_ACCESS_TOKEN": "shpat_xxx",
"REMOTE_MCP": "false"
}
}
}
}If you completed OAuth locally, remove SHOPIFY_ACCESS_TOKEN and keep --domain.
Claude Desktop (npm package)
{
"mcpServers": {
"shopify": {
"command": "npx",
"args": [
"shopify-mcp",
"--accessToken",
"<YOUR_ACCESS_TOKEN>",
"--domain",
"<YOUR_SHOP>.myshopify.com"
]
}
}
}If you completed OAuth, omit --accessToken and keep --domain.
Config paths:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%/Claude/claude_desktop_config.json
Remote MCP (Railway, etc.)
By default this server runs as a local stdio MCP. Passing --remote (or setting
REMOTE_MCP=true) switches it to HTTP/SSE mode so it can be deployed as a remote
MCP server for Claude.ai or other remote clients. This repo ships a Dockerfile
and railway.json so Railway builds and starts it in remote mode out of the box.
1. Get a token locally (one-time):
npx shopify-mcp --oauth --domain=your-store.myshopify.com --clientId=xxx --clientSecret=yyy
# Token saved to ~/.shopify-mcp/tokens.json2. Deploy to Railway:
Create a project from this repo. Railway reads
railway.jsonand builds theDockerfile, which starts the server with--remote.Set the service environment variables (Railway injects
PORTautomatically):
SHOPIFY_ACCESS_TOKEN=shpat_xxx # from tokens.json (or use the OAuth vars)
MYSHOPIFY_DOMAIN=your-store.myshopify.com
MCP_API_KEY=choose-a-long-random-string # required to authenticate remote clients
# REMOTE_MCP=true is already implied by the Dockerfile's --remote flag
# PORT is injected by Railway (defaults to 3000 when run locally)3. Connect:
Health check:
GET /healthMCP endpoint (SSE):
GET /mcp?apiKey=<MCP_API_KEY>Messages:
POST /messages?apiKey=<MCP_API_KEY>
Auth uses the apiKey query parameter; requests without a matching
MCP_API_KEY receive 401.
Test the container locally before deploying:
docker build -t shopify-mcp .
docker run -p 3000:3000 \
-e MYSHOPIFY_DOMAIN=your-store.myshopify.com \
-e SHOPIFY_ACCESS_TOKEN=shpat_xxx \
-e MCP_API_KEY=test \
shopify-mcp
# then in another shell: curl localhost:3000/healthEnvironment variables (optional)
SHOPIFY_ACCESS_TOKEN=your_access_token
MYSHOPIFY_DOMAIN=your-store.myshopify.com
# Optional OAuth values:
# SHOPIFY_CLIENT_ID=your_client_id
# SHOPIFY_CLIENT_SECRET=your_client_secret
# SHOPIFY_SCOPES=comma,separated,scopes
# Hide every mutating or unreviewed tool (also available as `--read-only`):
# SHOPIFY_MCP_READ_ONLY=trueTool catalog
Products
products— unified lookup/search/filter. Passidfor a single product; omitidto list/search with filters (title,status,vendor,tag, inventory, dates,hasImages, …). Returns the product's Shopify Standard Product Taxonomycategory({id, name, fullName}) inslim/standard/full. Page size capped at 100.create-productupdate-product— acceptscategory(Shopify Standard Product Taxonomy GID,vp-*prefix); the tool verifies the category actually stuck and throws a loud, actionable error if Shopify silently rejected the GID, instead of leaving you with a nullcategory.delete-productdelete-variantdelete-product-imagesbulk-update-productsbulk-delete-productscount-products-by-tagfind-products-by-metafield— list products that have / don't have / both for a givennamespace.key, paginated across the whole catalog via cursorsearch-taxonomy— browse Shopify's product category taxonomy; setincludeAttributes:trueto also return each category's attributes (e.g. Color, Pattern) and their allowed values
Collections
get-collectionsmanage-collection-productscreate-collectionupdate-collectiondelete-collection
Customers
get-customers(supports pagination viacursor)update-customer
Orders
orders— unified lookup/list. Passidfor a single order; omitidto list with filters (customerId,status, pagination viacursor). Replacesget-orders,get-order-by-id, andget-customer-orders.update-order
Draft Orders
draft-orders— unified lookup/list. Passidfor a single draft order; omitidto list with filters (status,query, pagination viacursor).create-draft-orderupdate-draft-ordercomplete-draft-order
Inventory
get-inventory-levelsupdate-inventory
Locations
get-locations
Metafields
get-metafields— server-side filter withkey+namespace(single field) orkeys: ["namespace.key", …](multi) via Shopify's nativemetafields(keys:); setincludeDefinitions:trueto merge ALL definitions with current values so empty/unfilled fields show up (value:null,isSet:false)set-metafield(create or update; supportsmetaobject_reference/list.metaobject_reference)bulk-set-variant-metafields— set metafields across many variants of one product in a singleproductVariantsBulkUpdatecall (up to 250 variants/call). UNIFORM mode (metafields) fans one value out to every variant and auto-discovers the variant IDs; PER-VARIANT mode (variants) sets different values per variant. Avoids oneset-metafieldcall per variant.delete-metafieldlist-metafield-definitions— discover metafield definitions for an owner type (PRODUCT, ORDER, CUSTOMER, …); each entry now includesconstraints(e.g.{key:"category", values:["vp-2","vp-2-2-3", …]}) so agents can see category-gating before writing (e.g.vehicle_*requiresvp-2*Vehicle categories; values on disallowed categories are silently filtered out by Shopify on read).get-metafield-options— resolve a metafield's selectable options in one call (for metaobject-reference fields, returns the available metaobject entries; for choice-lists, the allowed choices)
Metaobjects
list-metaobject-definitionsget-metaobject-definitioncreate-metaobject— optionalstatus(ACTIVE/DRAFT); defaults to Shopify'sDRAFTfor publishable definitions, passACTIVEto publish on createupdate-metaobject— edit fields on an existing entry (only provided keys change); optionalstatusto publish (ACTIVE) or unpublish (DRAFT)delete-metaobjectlist-metaobjects— returnsstatusper entry; optionalstatusfilter (applied client-side to the fetched page)get-metaobject— returns the entry's publishstatus
Files
get-files— list/search files in the storeattach-file-to-product— attach an existing media file to a productdetach-file-from-product— remove a media file from a productcreate-file-upload-session— start a browser upload session (remote mode only)get-file-upload-session— check an upload session (remote mode only)
URL redirects
get-redirectscreate-redirectdelete-redirect
Analytics
get-store-counts- Get all key counts in one call (products, variants, orders, customers, collections)get-product-issues- Audit products for problems (zero inventory, low stock, missing images, zero price)
Bulk Operations
start-bulk-export- Start async bulk export (products, orders, customers, inventory, or custom query)get-bulk-operation-status- Check progress of bulk operationget-bulk-operation-results- Download and parse completed results (summary, sample, or full)
Server
get-status- Report MCP server status, configured store, and connection health
Debugging
Tail Claude Desktop logs:
tail -n 20 -f ~/Library/Logs/Claude/mcp*.logLicense
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseCqualityDmaintenanceA Model Context Protocol server that provides comprehensive access to the Shopify Admin GraphQL API, enabling AI assistants to manage Shopify stores programmatically.1001MIT
- AlicenseCqualityCmaintenanceAn MCP server providing AI agents with full access to the Shopify Admin API via 136 tools for managing products, orders, customers, collections, and more.10012MIT
- Alicense-qualityDmaintenanceA comprehensive MCP server for Shopify Admin API integration, enabling AI assistants to manage products, orders, customers, inventory, analytics, and more through natural language.1718MIT
- Alicense-qualityDmaintenanceProduction-grade MCP server for the Shopify Admin GraphQL API, exposing typed tools for AI agents to manage products, orders, customers, and more.10MIT
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
A Model Context Protocol server for Wix AI tools
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/benwmerritt/shopify-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server