Production-ready Model Context Protocol (MCP) server for the Pexels API — search and browse photos and videos, with license-aware usage guidance. Unofficial; not affiliated with or endorsed by Pexels.
Setup
Choose your client, copy the config, then fill in any required environment variables.
claude mcp add pexels-server-hanoak --env PEXELS_API_KEY='<PEXELS_API_KEY>' -- npx -y @hanoak/pexels-mcp-server~/.codex/config.toml
[mcp_servers.pexels-server-hanoak]
command = "npx"
args = ["-y", "@hanoak/pexels-mcp-server"]
env = { PEXELS_API_KEY = "<PEXELS_API_KEY>" }
# codex mcp add pexels-server-hanoak --env PEXELS_API_KEY='<PEXELS_API_KEY>' -- npx -y @hanoak/pexels-mcp-server~/.cursor/mcp.json
{
"mcpServers": {
"pexels-server-hanoak": {
"command": "npx",
"args": [
"-y",
"@hanoak/pexels-mcp-server"
],
"env": {
"PEXELS_API_KEY": "<PEXELS_API_KEY>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"pexels-server-hanoak": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@hanoak/pexels-mcp-server"
],
"env": {
"PEXELS_API_KEY": "<PEXELS_API_KEY>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"pexels-server-hanoak": {
"command": "npx",
"args": [
"-y",
"@hanoak/pexels-mcp-server"
],
"env": {
"PEXELS_API_KEY": "<PEXELS_API_KEY>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"pexels-server-hanoak": {
"command": "npx",
"args": [
"-y",
"@hanoak/pexels-mcp-server"
],
"env": {
"PEXELS_API_KEY": "<PEXELS_API_KEY>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"pexels-server-hanoak": {
"command": "npx",
"args": [
"-y",
"@hanoak/pexels-mcp-server"
],
"env": {
"PEXELS_API_KEY": "<PEXELS_API_KEY>"
}
}
}
}Environment variables
PEXELS_API_KEY
Replace the placeholders with your own credentials and keep them out of version control.