Google Photos MCP
Summary: Use Google Photos through this MCP server/CLI to pick, organize, annotate, upload, download, and inspect photos/videos within Google Photos API limits.
Open Google’s photo picker, poll until the user finishes, list picked media, and download picked items as base64.
Create, list, get, rename, set cover photos for, share, unshare, and list shared albums.
Add or remove up to 50 app-created media items per album and insert album enrichments such as captions, locations, or maps between photos.
List or search app-uploaded media by date, category, media type, favorites, or archive status; describe valid filters; fetch one or many items; update descriptions; download media.
Upload from public URLs or local files, copy picked items into the app’s library, and create an album with media in one call.
List connected Google accounts, check auth/scopes and daily quota, and call raw Google Photos Library or Picker API endpoints.
Safety limits: uploads require explicit confirmation, media cannot be deleted through the API, and whole-library access only works through the user picker.
Provides integration with Google Photos, enabling AI agents to pick media via Google's picker, upload photos and videos, create and share albums, write captions and descriptions, and manage media metadata.
Click on "Deploy 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., "@Google Photos MCP I want to put my Iceland shots into a shared album."
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.
Google Photos MCP Server & CLI
Google Photos MCP server and CLI for Claude Code, Codex and AI agents. 26 tools for the photo picker, uploads, albums, enrichments, descriptions and app-created media.
One install gives you both surfaces, the same tools under the same names.
It opens Google's own picker, so you choose exactly what the agent sees. It uploads photos and videos, builds albums, writes captions, and adds the enrichments that make an album read as a story.
Google removed whole-library read access for every third-party app on 31 March 2025. Asking you to choose is the only route left, so this is built around the picker rather than pretending otherwise.
Connect as many Google accounts as you need.
Built and maintained by Navid Moazzez. Built on Slipway, which turns one definition of each tool into the MCP server and the CLI.
Two ways to use it
Command line
google-photos-cli in your terminal, for scripting, cron, pipes, or a quick
question without opening anything:
google-photos-cli # every command, one line each
google-photos-cli start-pick-session # hand yourself a picker URL
google-photos-cli check-pick-session --session-id abc # have you finished picking?
google-photos-cli list-picked-media --session-id abc
google-photos-cli list-albums --json | jq -r '.items[].title'
google-photos-cli create-album --title "Q3 Launch"
google-photos-cli upload-file --path ./shot.jpg --confirm
google-photos-cli <command> --help # what any command takes--confirm is the shell spelling of the confirmation that uploading requires.
--json gives JSON, --compact puts it on one line, --select keeps only the
fields you name, and errors are JSON on stderr whichever you pick.
google-photos-cli schema <command> prints the exact JSON Schema an MCP client
receives for that tool, which is how you can check the two surfaces really are
one thing.
MCP server, for your AI app
google-photos-mcp is what Claude Code, Claude Desktop, Cursor and the rest
launch. You never run it by hand:
claude mcp add google-photos \
-e GOOGLE_PHOTOS_CLIENT_ID=your-client-id \
-e GOOGLE_PHOTOS_CLIENT_SECRET=your-client-secret \
-e GOOGLE_PHOTOS_REFRESH_TOKEN=your-refresh-token \
-- npx -y @thenavidm/google-photos-mcp-cliThen just ask: "let me pick a few photos, then put them in a new album with a caption between the second and third."
Each upload waits for your approval in the client, as section 8 explains.
Every other client is in section 4.
Which one
Where you are | What you can reach |
An agent that can run shell commands, like Claude Code or Cursor | Both. The CLI is the cheaper one: it costs nothing until you type it |
claude.ai, the Claude Desktop chat tab, or a phone | The server only. There is no shell to run a command in |
A terminal, a script, cron or CI | The CLI only. There is no MCP client in a shell |
They are the same program reading the same tool definitions, so anything one can do, the other can.
Related MCP server: Photo Organizer MCP Server
Features
Every tool is both a command and an MCP tool, with the same name. The command is the tool name with dashes.
Capability | CLI command | MCP tool |
Pick from your library |
|
|
Albums |
|
|
Captions, places and maps inside an album |
|
|
Media this server uploaded |
|
|
Upload |
|
|
The connection |
|
|
Sign in once |
| not a tool |
Check your setup |
| not a tool |
All 26 are in section 7.
Contents
# | Section | What is in it |
1 | Real prompts, not features | |
2 | No account needed | |
3 | Every click, start to finish | |
4 | Every client, copy and paste | |
5 | One command | |
6 | Measured in Claude Code, and how to spend less | |
7 | All 26, grouped by what they reach | |
8 | What the API will not do | |
9 | Symptom to cause | |
10 | The questions people actually ask |
1. What you can ask it 💬
Let me pick some photos, then tell me what I chose.
Put these six product shots in a new album called "Q3 Launch".
Which of the ones you uploaded are videos, and how long are they?
Write a description on everything in the launch album.
Rename the Iceland album and set the third photo as its cover.
Save what I just picked into my library so you can organize it later.
Upload this to my brand account, not my personal one.
Download the third photo I picked and tell me whether it is sharp enough to print.
What can you actually see in my Google Photos, and what can you not?
Add a caption between the second and third photo, then a map from Reykjavik to Vik.
The last one is the point. An album enrichment is a caption, a place, or a map between two points, sitting inline between the photos rather than in a description nobody opens. It is what makes an album read as a story, and almost nothing outside Google's own app drives it.
2. Quick install ⚡
Node 22 or newer. Nothing else.
npx -y @thenavidm/google-photos-mcp-cli --versionThat is the whole install. npx fetches it on demand, so there is nothing to
update later.
Installing the package needs no account. Only the config in section 4 does.
3. Setup 🔑
Google Photos has no API keys, and Google does not support service accounts for these APIs at all. The only way in is an OAuth client that you create, in a Google Cloud project that you own, authorized by the account whose photos you want to reach.
About ten minutes, once. It is free and you will not be asked for a card.
Before you start
You need | Check with | If missing |
Node 22 or newer |
| |
A Google account | You have one | Any account works, personal or Workspace |
It has to be the account that owns the photos, or one you are willing to sign in as.
Have an agent do it
The agent cannot sign in to Google for you. Only you can create the credential. What it can do is walk you through it, wire up the config, and verify the connection.
Paste this into Claude Code, Cursor, or any agent with terminal access:
Help me set up the Google Photos MCP server.
1. Open https://console.cloud.google.com/projectcreate and tell me what to name a project.
2. Walk me through enabling the Photos Picker API and the Photos Library API. Both.
3. Walk me through the Google Auth Platform consent screen, adding me as a test user,
and adding these four scopes:
https://www.googleapis.com/auth/photospicker.mediaitems.readonly
https://www.googleapis.com/auth/photoslibrary.appendonly
https://www.googleapis.com/auth/photoslibrary.readonly.appcreateddata
https://www.googleapis.com/auth/photoslibrary.edit.appcreateddata
4. Walk me through creating a Web application OAuth client with
http://localhost:4180 as an authorized redirect URI.
5. STOP and wait. I will paste you the client ID and client secret.
6. Then run: GOOGLE_PHOTOS_CLIENT_ID=... GOOGLE_PHOTOS_CLIENT_SECRET=... \
npx -y @thenavidm/google-photos-mcp-cli auth
and tell me to approve it in the browser.
7. Add all three values to my MCP client config, then run doctor to verify.Or do it yourself
Console labels move. Where a step names a button, that is what it was called at the time of writing. Where it describes a goal instead, that is deliberate.
Step 1: Create a project.
Go to console.cloud.google.com and create a project. Name it something you will recognize in six months.
A project is just a container for the API access and the OAuth client. An existing one works, but a fresh one keeps this credential separate from everything else, which makes it safe to delete later.
Step 2: Turn on both APIs.
Google Photos is two separate APIs and this server uses both. Enabling one and
not the other gives you a half-working state where picking succeeds and albums
return 403.
Each link opens that API in your project. Click to enable, go back, do the other.
Check the project picker in the top bar first. Enabling an API in the wrong project is the single most common way to lose half an hour here.
Step 3: Configure the consent screen.
This lives under Google Auth Platform. If the project has never been set up, its overview page offers a Get started button covering the same fields.
Field | What to put |
App name | Something plain, like |
User support email | Your own address, from the dropdown |
Audience | External, unless you have a Workspace organization and want to restrict it to people inside it |
Contact information | Your email again. This one is for Google to reach you |
Step 4: Add yourself as a test user.
On the Audience page, add your own Google account as a test user.
This is easy to skip and it is what causes access_denied at the end of
sign-in. While the publishing status is Testing, only accounts on that list
can authorize the app, up to 100 of them.
In Testing, an authorization expiresseven days after you grant it, and the refresh token expires with it. Your setup works, then stops a week later for no visible reason. Set the publishing status to In production on the same page to stop that. For personal use this needs no verification review; you click past an "unverified app" warning during sign-in.
Step 5: Add the scopes.
On the Data access page, add these four. If one is not in the list, paste it in manually.
https://www.googleapis.com/auth/photospicker.mediaitems.readonly
https://www.googleapis.com/auth/photoslibrary.appendonly
https://www.googleapis.com/auth/photoslibrary.readonly.appcreateddata
https://www.googleapis.com/auth/photoslibrary.edit.appcreateddataOlder guides ask for photoslibrary or photoslibrary.readonly. Do not add
those. Google removed them on 1 April 2025, and a project requesting one now
fails at the consent screen rather than degrading. The four above are the
complete set still available.
Step 6: Create the OAuth client.
On the Clients page, create a client.
Application type: Web application. Not "Desktop app". A desktop client cannot be given a redirect URI, and the sign-in command needs one to catch the response.
Authorized redirect URI:
http://localhost:4180, exactly, with no trailing slash.
That port is where the auth command listens. If 4180 is busy, register
http://localhost:<your port> instead and set GOOGLE_PHOTOS_AUTH_PORT to
match. The string has to match byte for byte or Google returns
redirect_uri_mismatch.
Save, then copy the client ID and client secret. The secret is shown once.
Step 7: Get a refresh token.
export GOOGLE_PHOTOS_CLIENT_ID="your-client-id"
export GOOGLE_PHOTOS_CLIENT_SECRET="your-client-secret"
npx -y @thenavidm/google-photos-mcp-cli authA browser opens. Sign in as the account whose photos you want, click past the unverified-app warning, and approve the four permissions. The command prints a refresh token.
If it prints none, this account has already consented to this client before. Remove the app at myaccount.google.com/permissions and run it again.
Revoking
myaccount.google.com/permissions, find the app, remove it. That kills every token from that client at once.
The refresh token reaches your photo library until you do. Treat it like a password: never paste one into an issue, a gist, or a chat.
4. Connect your client 🔌
All three values go in every block below.
Claude Code
claude mcp add google-photos \
-e GOOGLE_PHOTOS_CLIENT_ID=your-client-id \
-e GOOGLE_PHOTOS_CLIENT_SECRET=your-client-secret \
-e GOOGLE_PHOTOS_REFRESH_TOKEN=your-refresh-token \
-- npx -y @thenavidm/google-photos-mcp-cli@latest--scope user makes it available in every project rather than the current one.
Then run /mcp to confirm it is connected. Remove it with
claude mcp remove google-photos.
Claude Desktop
Platform | Path |
macOS |
|
Windows |
|
{
"mcpServers": {
"google-photos": {
"command": "npx",
"args": ["-y", "@thenavidm/google-photos-mcp-cli@latest"],
"env": {
"GOOGLE_PHOTOS_CLIENT_ID": "your-client-id",
"GOOGLE_PHOTOS_CLIENT_SECRET": "your-client-secret",
"GOOGLE_PHOTOS_REFRESH_TOKEN": "your-refresh-token"
}
}
}
}Quit Claude Desktop completely and reopen it. On macOS use Cmd+Q; closing the window is not enough.
Claude Desktop does not inherit your shell PATH, so a barenpx can fail.
Use the absolute path from which npx as the command.
claude.ai on the web
claude.ai runs connectors from Anthropic's cloud, not from your machine, so it cannot launch a local command. It needs a public HTTPS URL.
npx -y @thenavidm/google-photos-mcp-cli@latest --http --port 8000Host that somewhere with a public HTTPS URL, then in claude.ai: Customize, Connectors, +, Add custom connector. Paste the URL and click Add.
On Team and Enterprise an owner adds it first under Organization settings, Connectors, then each member enables it under Customize, Connectors. Free is limited to one custom connector. A server behind a VPN or firewall will not connect.
Cursor
~/.cursor/mcp.json for every project, or .cursor/mcp.json for one. Same JSON
as Claude Desktop, key mcpServers. Reload the window afterwards.
Windsurf
~/.codeium/windsurf/mcp_config.json, same JSON, key mcpServers, then reload.
VS Code
.vscode/mcp.json. The key is servers, not mcpServers, and each entry
needs a type:
{
"servers": {
"google-photos": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@thenavidm/google-photos-mcp-cli@latest"],
"env": {
"GOOGLE_PHOTOS_CLIENT_ID": "your-client-id",
"GOOGLE_PHOTOS_CLIENT_SECRET": "your-client-secret",
"GOOGLE_PHOTOS_REFRESH_TOKEN": "your-refresh-token"
}
}
}
}Codex CLI
~/.codex/config.toml:
[mcp_servers.google-photos]
command = "npx"
args = ["-y", "@thenavidm/google-photos-mcp-cli@latest"]
[mcp_servers.google-photos.env]
GOOGLE_PHOTOS_CLIENT_ID = "your-client-id"
GOOGLE_PHOTOS_CLIENT_SECRET = "your-client-secret"
GOOGLE_PHOTOS_REFRESH_TOKEN = "your-refresh-token"Gemini CLI
~/.gemini/settings.json, same JSON as Claude Desktop, key mcpServers.
More than one Google account
Swap the three single-account variables for GOOGLE_PHOTOS_ACCOUNTS, a JSON
array. Each account carries its own client id and secret, because a refresh
token only works with the OAuth client that minted it. Two Google accounts
authorized through the same Cloud project can reuse the same pair.
{
"mcpServers": {
"google-photos": {
"command": "npx",
"args": ["-y", "@thenavidm/google-photos-mcp-cli@latest"],
"env": {
"GOOGLE_PHOTOS_ACCOUNTS": "[{\"name\":\"personal\",\"client_id\":\"...\",\"client_secret\":\"...\",\"refresh_token\":\"...\"},{\"name\":\"brand\",\"client_id\":\"...\",\"client_secret\":\"...\",\"refresh_token\":\"...\"}]",
"GOOGLE_PHOTOS_DEFAULT_ACCOUNT": "personal"
}
}
}
}Run auth once per account, signing in as a different Google account each time.
Then pass account: "brand" on any tool, or leave it off and the default acts.
list_accounts shows what is connected.
An exact name wins over a prefix, so personal and personal-archive stay
distinct rather than resolving to whichever came first.
Everything else
Zed, Cline, Continue and anything else that speaks MCP over stdio take the same
three things: the command npx, the args, and the env block.
Docker
docker build -t google-photos-mcp .
docker run -i --rm \
-e GOOGLE_PHOTOS_CLIENT_ID=your-client-id \
-e GOOGLE_PHOTOS_CLIENT_SECRET=your-client-secret \
-e GOOGLE_PHOTOS_REFRESH_TOKEN=your-refresh-token \
google-photos-mcp5. Check it worked 🩺
npx -y @thenavidm/google-photos-mcp-cli@latest doctordoctor checks four things in the order they fail and stops at the first real
problem: credentials present, refresh token mints an access token, every scope
actually landed in the grant, and one live API call.
Symptom | Cause |
| A value is not reaching the server. Check the JSON is valid |
| Seven days passed with the consent screen in Testing, or the token was revoked |
| A scope was added after the token was minted. Run |
6. Which surface, and what each costs
Both surfaces are the same program with the same 26 tools. The difference is when the model pays for them. Measured in Claude Code:
Cost | MCP server | CLI |
Every message, with every tool loaded | 10,200 tokens | nothing |
Every message, Claude Code's default | 900 tokens | nothing |
When Google Photos comes up | nothing more, or the tools it picks | 3,940 tokens for |
20 messages with Google Photos in 1, every tool loaded | 204,000 tokens | 3,940 tokens |
Claude Code's tool search is on by default: it sends only the tool names and the server instructions, and loads a tool's full definition when the model reaches for it. An app that loads every tool up front pays the first line on every message, whether Google Photos comes up or not. With the skill added, Claude Code also lists its one-line description, about 160 tokens.
To spend less, turn the server off when you are not using it, which in Claude
Code is the /mcp panel. GOOGLE_PHOTOS_READ_ONLY=1 takes the 11 write tools off the list, leaving 15.
Or install the CLI and add the server on the days it earns its place.
Measured on 2026-10-05 with Claude Code 2.1.286 on Claude Opus 5.5: one
short prompt with and without the server connected, once with
ENABLE_TOOL_SEARCH=false and once with the default, the difference read
from the API's own usage figures. SKILL.md was measured the same way. Other
apps and models count tokens a little differently.
Against 1.2.0, measured the same day: every tool loaded costs 10,183 tokens
instead of 11,124, tool search the same, and SKILL.md 117 more, because it now
says how approval works over MCP, lists every exit code and shows --select
reaching into a list. In Codex 0.159.3 on gpt-6.1-sol, the same task, "find the
command that puts photos into an existing album and the flags it requires",
read a median of 83,618 input tokens on 2.0.0 against 83,623 on 1.2.0 over the
CLI, and 48,638 against 48,613 over MCP, five runs each. Codex prints the tool
list from a script and keeps the same share of it on both sides; 2.0.0's list
is 268 characters shorter, so the kept part holds slightly different text, 25
tokens longer by the model's count (9,319 against 9,294), which is the whole
difference.
7. Tools 🛠️
26 tools. Read-only mode leaves 15.
Picking from your library
The only route to photos this server did not upload. Asynchronous by design: a human has to actually use the URL before anything is visible.
Tool | What it does |
| Open a picker and return a URL for the user |
| Poll until the user has finished choosing |
| List what they picked |
| Fetch a picked item's bytes as base64 |
Albums
Tool | What it does |
| Create an empty album |
| List albums this server created |
| One album, with its cover and item count |
| Rename, or set the cover photo |
| Add up to 50 items |
| Remove up to 50, keeping them in the library |
| Insert a caption, a place, or a map between photos |
Media
Tool | What it does |
| List media this server uploaded, optionally by album |
| Filter by date, content category, media type, favorites |
| Every valid filter value, and what is not possible |
| One item |
| Up to 50 items in one request |
| Set a description |
| Fetch bytes as base64, resolving a fresh URL first |
Uploading
Tool | What it does |
| Upload up to 20 files from public URLs |
| Upload a local file |
| Copy picked items in, so the other tools can reach them |
| Create an album and fill it in one call |
The connection
Tool | What it does |
| Every connected Google account, and which one is the default |
| Which account, which scopes, and what is missing |
| How much of the daily budget is left |
| Call an endpoint this server does not wrap |
Resources and prompts
Two resources: google-photos://status for the connection, and
google-photos://capabilities for a plain account of what the API can and
cannot do. A model that reads the second stops proposing things Google removed.
Three prompts: pick-and-work, build-album, and diagnose.
8. Notes and gotchas 📓
Google removed whole-library read on 31 March 2025, and shipped the change
on 1 April. The photoslibrary, photoslibrary.readonly and
photoslibrary.sharing scopes are gone for third-party apps, with no
replacement. Any tool offering to search your entire library is either on a
grandfathered grant or searching only what it uploaded and calling that your
library.
There is no sharing. albums.share, albums.unshare and every
sharedAlbums method were removed in the same change and now return
403 PERMISSION_DENIED for every app. Google's own answer is that the user
shares an album by hand in the Google Photos app, so this server ships no
sharing tools rather than four that always fail.
So an empty listing means "this server uploaded nothing", not "you have no photos." The tool descriptions say so, so a model does not report it wrongly.
There is no delete. No endpoint exists to remove a media item, for anyone. An upload is permanent as far as any API is concerned, and has to be removed by hand in the Google Photos app. This is why each upload waits for your approval.
There is no free-text search. You cannot search for "beach". Content
categories are Google's own classifier and are the nearest equivalent. Call
describe_filter_capabilities rather than guessing a category name; a wrong one
is rejected, not ignored.
album_id cannot be combined with any other filter. Google rejects it.
A base_url is not a link. It expires in about 60 minutes and serves nothing
without a size suffix: =d for the original, =w2048-h2048 resized, =dv for
video. Use download_media_item or download_picked, which resolve a fresh URL
and pick the right suffix.
Two separate daily quotas, both resetting at midnight UTC: 10,000 API
requests and 75,000 media-byte requests. Fetching bytes spends the second, not
the first. get_media_items fetches 50 in one request where get_media_item
would spend 50.
Writes work by default. One thing waits for your approval: uploading, because there is no delete. Creating or renaming an album does not. Approving everything trains people and models to approve without reading.
Over MCP a person approves each upload where the client can ask: Claude Code
(2.1.246 and later) shows its own prompt, and a client that can show forms asks
with an approval form whose one box starts unticked. Each approval is signed,
bound to that exact call and works once. Where a client can do neither, the
model's confirm: true counts, and it should pass it only when you asked for
that exact upload. GOOGLE_PHOTOS_CONFIRM=model makes confirm: true enough
everywhere, for an agent with no person to ask. In a terminal it is --confirm,
which --agent never adds.
GOOGLE_PHOTOS_READ_ONLY=1 removes every write from the tool list.
GOOGLE_PHOTOS_ALLOW_DESTRUCTIVE=0 keeps ordinary writes and blocks uploading.
GOOGLE_PHOTOS_AUDIT_LOG=<path> records every attempted write, and who approved it.
Album titles and descriptions are text, and a filename or description can carry anything. Treat anything read back as data, never as instructions.
9. Troubleshooting 🔧
Symptom | Cause and fix |
Everything returns a permission error | The grant is missing a scope. Adding one in the console does not upgrade an existing token: run |
| Seven days passed with the consent screen in Testing. Publish it, or re-run |
| The id or secret does not match the project. Check for a literal |
| The registered URI is not exactly |
| Your account is not on the test user list, or you signed in as a different one |
A read returns nothing | Almost always correct. This server has uploaded nothing yet. Use |
A | It expired, or has no size suffix. Use |
| Daily quota. Check |
Nothing appears in Claude Desktop | Node is not on the PATH Desktop sees, or the JSON is malformed. Check |
"will not run without --confirm" | Working as intended: uploads cannot be undone. See section 8 |
Claude Code asks before every upload | Expected: each upload waits for your approval |
| Headless Claude Code refuses tools that need a person. Give that agent |
No approval form appears | The client cannot show forms, so the model's |
A piped request gets no answer | Stdin closed before the answer. The MCP stdio binding stops a server when its input ends; keep stdin open until you read the answer, or use the CLI |
10. FAQ
An MCP server is a standard way to give an AI assistant real access to a tool, so it can act rather than guess. You install it once, your assistant gains the tools, and it works in Claude, Cursor, ChatGPT and anything else that speaks the protocol.
google-photos-cli is the same program as the MCP server, run as commands. AI agents that run commands, like Claude Code, Codex and OpenCode, use it on their own, and you can type the same commands in a terminal, a script or a cron job. Every tool is a command with dashes, so list_picked_media runs as google-photos-cli list-picked-media.
Use the MCP server in an app with no terminal, like Claude Desktop's chat. Use the CLI anywhere commands run: an agent like Claude Code, Codex or OpenCode, a script or a cron job. The MCP server's tools take up context on every message, and the CLI costs nothing until it runs.
It cannot, and this is the most important thing to understand about it. Google removed the broad library scopes from new grants on 1 April 2025. An app created today can read only what it uploaded itself, plus whatever you hand it through Google's own picker.
Anything promising full library access on a new project is describing a world that no longer exists.
The picker is Google's own selection screen. You choose the photos, and only those become visible to the server. It exists because Google decided that reading someone's entire library should be the user's explicit choice each time rather than a permission granted once.
In practice you pick a set, the server reads it, and nothing else is exposed.
It asks for four narrow scopes: read what you picked, upload new media and create albums, read back only what this app created, and edit descriptions and album membership for that same app-created data. None of them grant access to photos it did not upload or you did not pick.
Nothing leaves your machine except calls to Google. There is no backend here, no account to create and no telemetry. Your credential sits in your client's config or your local data directory.
It cannot delete anything. Google's API exposes no delete for library media, so there is nothing to call. The strongest thing it does is edit descriptions and album membership for items it created itself.
It uploads and creates albums when you ask it to. Each upload waits for your
approval: Claude Code shows its own prompt for each one, and a client that can
show forms asks with one. Where a client can do neither, the model's
confirm: true counts, which is a speed bump against a careless call rather
than a lock. Setting GOOGLE_PHOTOS_READ_ONLY=1 removes every write tool from
the list, so the model cannot see or call them.
It costs nothing. The server is MIT licensed and the Google Photos API is free. Uploads count against your normal Google storage, the same as any other upload.
It works with any MCP client. Claude Code, Claude Desktop, Cursor, Windsurf, VS Code, Codex CLI and Gemini CLI all run it the same way.
Remove the app's access at myaccount.google.com under Security, then Third-party apps, which invalidates the token immediately. Then remove the server from your client's config.
It is scoped to four permissions and no more: read what you pick, upload, read back what it uploaded, and edit what it created. It cannot read your existing photos and cannot reach any other Google service.
It still reaches a real photo library, so treat it as a password. Revoke it at myaccount.google.com/permissions.
Google Photos has no API keys and does not support service accounts for these APIs. A user OAuth grant is the only way in, and a grant needs a client. It is about ten minutes, once, and it is free.
The OAuth consent screen is still in Testing, where Google expires authorizations after seven days and the refresh token with them. Set the publishing status to In production on the Audience page.
Not for your own use. You click past an "unverified app" warning during sign-in. Verification matters only when other people will use your client, and Google Photos scopes need a separate review on top of the usual one.
Yes. Set GOOGLE_PHOTOS_ACCOUNTS to a JSON array instead of the three single-account variables, run auth once per account, and pass account: "brand" on any tool. list_accounts shows what is connected. Section 4 has the config block.
Yes, but claude.ai runs connectors from Anthropic's cloud, so it needs the HTTP transport hosted somewhere with a public HTTPS URL. Section 4 covers it.
GOOGLE_PHOTOS_READ_ONLY=1. The write tools are not registered at all, so a model cannot call what it cannot see, and the list drops from 26 tools to 15.
doctor. It tests credentials, scopes and a live API call, and names the first real problem rather than leaving you to guess.
Environment variables
Three are required. Everything else has a working default and exists so you can tighten or tune it.
Credentials
Variable | What it is |
| OAuth client id, from your own Google Cloud project. Section 3 creates one |
| The matching client secret |
| From |
| A JSON array instead, for several Google accounts at once. Replaces the three above |
| Which account acts when a tool names none. Comma-separated, in order of preference. Defaults to the first configured |
Safety
Variable | Default | What it does |
|
|
|
|
|
|
| none | Path to an append-only JSON-lines record of every attempted write, and who approved it |
|
|
|
|
|
|
| none | Give up on any tool after this long |
|
|
|
Tuning
Variable | Default | What it does |
|
| Per-request deadline |
|
| Retries on 429 and 5xx, for idempotent verbs only |
|
| Loopback port |
Serving over HTTP (--http, read SECURITY.md before you use it)
Variable | Default | What it does |
|
| Port to bind |
|
| Interface to bind. Widen it only if you mean it |
| none | Bearer token. Any address but localhost refuses to start without one |
| none | Comma-separated browser origins allowed to connect; a page from any other site is refused |
Versions
See CHANGELOG.md, newest first, with the upstream API and action versions this was last checked against.
Questions
Run into a problem or have a question? Open an issue and I will help.
Built by
Navid Moazzez
Navid Moazzez is a leading AI business strategist, and the host of the AI Creator Summit, watched by 100,000+ creators. He helps creators and founders master AI and build their own AI Operating System (AI OS) to automate their business and life. He creates useful free tools, MCP servers and CLIs that creators and founders can use in their own workflows.
Dependencies
Library | License | What it does |
Apache-2.0 | The MCP server and the CLI from one definition of each tool, with the write guard | |
Apache-2.0 | The MCP protocol and transports, through Slipway | |
MIT | Tool argument schemas and validation |
Security
Found a vulnerability? Report it privately, not as a public issue. SECURITY.md covers what this server holds, the write-safety model, and running it over HTTP.
License
MIT. Free to use, modify, and share.
Not affiliated with, endorsed by, or connected to Google LLC.
© 2026 Navid Media. Made with ❤️ by Navid Moazzez.
Available Tools
29 toolsadd_album_enrichmentAdd a caption, location or map to an albumA
Insert an enrichment into an album: a text caption, a named location, or a map between two places. Enrichments sit between photos and are how an album reads as a story rather than a grid.
Position defaults to the end of the album.
Inputs: type (required), album_id (required), text, account, +10 more.
add_to_albumAdd media to an albumA
Add media items this app created to an album this app created. Both sides have to be app-created; a picked item cannot be added directly, it has to be uploaded into the library first with save_to_library.
Up to 50 items per call.
Inputs: album_id (required), media_item_ids (required), account.
auth_statusCheck the Google Photos connectionARead-onlyIdempotent
Report whether the server can reach Google Photos, which account it acts as, and which scopes the grant actually carries.
Call this first when anything returns a permission error. A missing scope and a revoked token produce similar-looking failures and are fixed differently.
Inputs: account.
check_pick_sessionCheck whether the user has finished pickingARead-onlyIdempotent
Poll a picker session started by start_pick_session. ready is true once the user has confirmed a selection.
Respect the poll_interval_seconds from start_pick_session rather than polling in a tight loop. If it is still false after a few minutes, the user has probably not opened the link yet; ask them rather than polling forever.
Inputs: session_id (required), account.
create_albumCreate an albumA
Create a new, empty album in the user's Google Photos. It is private, and it belongs to this app, which is what makes it editable later. Add items with add_to_album or by passing album_id when uploading.
Inputs: title (required), account.
create_album_with_mediaCreate an album and fill it in one callADestructive
Create an album and upload files into it in a single step. Saves three round trips over create_album, upload_from_url and add_to_album, and leaves no empty album behind if the uploads fail.
There is no API to delete uploaded media. Requires confirm: true. Up to 20 URLs.
Inputs: urls (required), title (required), max_mb, account, +2 more.
describe_filter_capabilitiesList every filter value search_library acceptsARead-onlyIdempotent
Return the exact content categories, media types and feature filters search_library accepts, plus what the Google Photos API cannot do. Costs no API call and no quota.
Read this before guessing a category name. A wrong one is rejected rather than ignored.
Inputs: account.
download_media_itemDownload a media itemARead-onlyIdempotent
Fetch the bytes of a media item this app uploaded, returned as base64 with its mime type. Resolves the item's current base_url first, so it works with a plain id and never with a stale URL.
Inputs: media_item_id (required), size, max_mb, account.
download_pickedDownload a picked photo or videoARead-onlyIdempotent
Fetch the bytes of an item the user picked, returned as base64 with its mime type. Pass the item's base_url from list_picked_media.
Use this rather than giving a base_url to the user or to another tool: the URL needs an auth header and a size suffix, and it expires within the hour. Large files are refused; raise max_mb only when the caller genuinely needs the original.
Inputs: base_url (required), size, max_mb, account.
get_albumGet one albumARead-onlyIdempotent
Fetch a single album by id, including its item count, cover photo and sharing state.
A 404 here usually means the album exists but was not created by this app, rather than that the id is wrong. Only albums created by this app are listed. Albums the user made in the Google Photos app are not visible to any scope available since 2025-04-01.
Inputs: album_id (required), account.
get_media_itemGet one media itemARead-onlyIdempotent
Fetch a single media item by id, with its dimensions, creation time and description. Only media uploaded by this app is returned. To reach anything else in the user's library, use start_pick_session.
Inputs: media_item_id (required), account.
get_media_itemsGet several media items at onceARead-onlyIdempotent
Fetch up to 50 media items by id in one call. Prefer this over repeated get_media_item: it is one request against the daily quota rather than fifty. Only media uploaded by this app is returned. To reach anything else in the user's library, use start_pick_session.
Ids that cannot be read come back in failed with a reason, rather than failing the whole call.
Inputs: media_item_ids (required), account.
list_accountsList the connected Google accountsARead-onlyIdempotent
Show every Google account this server can act as, and which one acts when a tool names none.
Pass one of these names as account on any tool to act as that library instead of the default. Costs no API call.
Inputs: no named parameters.
list_albumsList albumsARead-onlyIdempotent
List the albums this app created, newest first. Only albums created by this app are listed. Albums the user made in the Google Photos app are not visible to any scope available since 2025-04-01.
Pass next_page_token from a previous result to continue; a library with many albums will not fit in one page.
Inputs: limit, account, page_token.
list_app_mediaList media this app uploadedARead-onlyIdempotent
List media items, newest first, optionally scoped to one album. Only media uploaded by this app is returned. To reach anything else in the user's library, use start_pick_session.
Pass next_page_token to continue past the first page.
Inputs: limit, account, album_id, page_token.
list_picked_mediaList what the user pickedARead-onlyIdempotent
Return the media items the user selected in a picker session. Call check_pick_session first; this returns an empty list until the selection is confirmed.
The items include a base_url that expires in about an hour. To get actual bytes, pass an item's base_url to download_picked rather than handing the URL to the user.
Inputs: session_id (required), limit, account, page_token.
quota_statusCheck how much daily quota is leftARead-onlyIdempotent
Report how much of the Google Cloud project's daily budget this server has spent: 10,000 API requests and 75,000 media-byte requests, both resetting at midnight UTC.
Counted by this process since it started, so it is a floor rather than a true reading. Worth checking before a long batch, and worth reading when calls start failing with RESOURCE_EXHAUSTED.
Inputs: no named parameters.
rawCall a Google Photos endpoint directlyA
Escape hatch for an endpoint this server does not wrap. Give a path relative to the API root and it is sent with the current access token.
Prefer a named tool where one exists: they shape the response, handle pagination and explain their errors. Reach for this when the API has something the tools do not cover yet.
Inputs: api (required), path (required), body, query, +2 more.
remove_from_albumRemove media from an albumA
Take media items out of an album. The items stay in the user's library; only the album membership goes. Up to 50 per call.
Inputs: album_id (required), media_item_ids (required), account.
save_to_libraryCopy picked media into this app's libraryADestructive
Take items the user chose in a picker session and upload them as app-created media, so the other tools can then read, describe and organise them.
This is the bridge between the two halves of the API. A picked item is readable only for the life of its session; once saved it is a normal media item this app owns. It does create a second copy in the user's library. Requires confirm: true.
Pass base_urls from list_picked_media, up to 20.
Inputs: base_urls (required), account, confirm, album_id.
search_librarySearch media by date, category or typeARead-onlyIdempotent
Filter media by date range, content category, media type or favourites. Only media uploaded by this app is returned. To reach anything else in the user's library, use start_pick_session.
There is no free-text search in the Google Photos API: you cannot search for "beach" as a word. Categories are the closest equivalent, and they are Google's own classifier, not tags the user set. Call describe_filter_capabilities for the exact values.
An album_id cannot be combined with any filter; Google rejects that combination.
Inputs: limit, account, album_id, end_date, +7 more.
start_pick_sessionStart a photo picker sessionARead-onlyIdempotent
Open a Google Photos picker so the user can choose photos and videos from their ENTIRE library. This is the only way to reach media this app did not upload itself; the Library API cannot see anything else.
Returns a picker_uri. Give that URL to the user and stop. They open it, select items in Google Photos, and finish. Then call check_pick_session until ready is true, and list_picked_media to see what they chose.
Do not call list_picked_media straight after this. Nothing has been picked yet and the empty result does not mean the library is empty.
Inputs: account.
update_albumRename an album or set its coverAIdempotent
Change an album's title, its cover photo, or both. The cover has to be a media item that is already in the album; setting one that is not returns an error.
Inputs: album_id (required), title, account, cover_media_item_id.
update_media_descriptionSet a media item's descriptionAIdempotent
Write the description shown under a photo or video in Google Photos. Only works on media this app uploaded. Passing an empty string clears it.
Inputs: description (required), media_item_id (required), account.
upload_fileUpload a local fileADestructive
Upload a photo or video from a path on the machine running this server, optionally straight into an album.
There is no API to delete a media item once uploaded. Requires confirm: true.
Inputs: path (required), account, confirm, album_id, +1 more.
upload_from_urlUpload photos or videos from URLsADestructive
Download files from public URLs and add them to the user's Google Photos, optionally straight into an album.
There is no API to delete a media item once uploaded, so this cannot be undone here: the user would have to remove it by hand in the Google Photos app. Requires confirm: true.
Up to 20 URLs per call.
Inputs: urls (required), max_mb, account, confirm, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 29 tools
The set is largely distinct: picker session tools form a clear multi-step workflow, album tools follow CRUD plus sharing, and media tools separate app-owned from picked items. A few pairs could be conflated (search_library vs list_app_media; upload_from_url vs create_album_with_media), but their descriptions resolve the boundaries well.
Most tools follow a consistent verb_noun snake_case pattern (list_albums, create_album, update_media_description, save_to_library). The deviations are minor: auth_status and quota_status are noun-like, and raw is a bare escape hatch, but they do not make the naming unpredictable.
At 29 tools, the surface is well past the 25-tool threshold and over double the typical well-scoped range. Although many operations are genuinely distinct, the set would be easier to navigate with consolidation, especially around upload entry points and singleton admin/status tools.
The domain is broadly covered: upload, search/list, media detail/download, album create/read/update/share/enrich, and the picker bridge to the full library. The main missing named operation is delete_album, and media deletion is impossible in the underlying API; raw provides an escape hatch for such gaps.
Maintenance
Related MCP Connectors
Sort, search and tidy your Google Photos from chat: find photos and videos, read their details, dow…
Search photos and video moments by visual meaning, people, dates, and folders across local libraries, Apple Photos, and OneDrive. Manage collections, groups, favorites, people, and duplicate review. Synced metadata remains searchable while the desktop is offline; local and Apple Photos media access needs the owning device online with remote access enabled. OneDrive media can be accessed directly from the cloud. OAuth or Bearer API keys. Paid Cloud Access required; hosted visual search uses prepaid credits. Text-in-image search is semantic matching, not guaranteed exact OCR. Setup: https://organizewith.ai/en/guides/connect-ai-assistants
Multiple Gmail accounts, editable Google Sheets & Docs for AI agents. Deny-by-default access rules.
Gmail, Outlook, Drive, OneDrive and calendars for AI agents. Many accounts, one endpoint, audit log.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to search, browse, and retrieve metadata and images from your Google Photos library. It supports content-based filtering, album listing, and location extraction via STDIO and HTTP transports.60MIT
- AlicenseAqualityDmaintenanceEnables AI agents to automatically organize Google Photos and Google Drive files, including deduplication and archiving.635 npmMIT
- AlicenseAqualityBmaintenanceEnables AI agents to search, inspect, organize, and export photos from a local Apple Photos library using natural language, including scene labels, text, faces, places, and albums.131MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to search, list, preview, and export photos from Apple Photos, Google Photos Picker sessions, and local Google Takeout archives using native search and metadata inspection.MIT