Endpoint Context Protocol (ECP) integration
ECP is a 2026 protocol that lets AI agents discover what your site is and what they can do here. They hit the same root URL a browser would, send Accept: text/markdown or application/ecp+json, and your server returns a structured markdown welcome instead of HTML. Two callers, same URL, content tailored to who's asking.
Why it matters
Agents in 2026 are moving from scraping HTML to asking sites directly: who are you, what can I do here, how should I cite you. ECP is the first widely-adopted convention for answering that. Sites that speak ECP get cleaner agent representations, better citations, fewer hallucinated facts.
The three pieces
An ECP-compliant site has three artifacts:
/ecp.json, the discovery manifest
Small JSON file at your site root pointing agents to your welcome document and your other AI-discovery files.
/AgentWelcome.md, the markdown greeting
Single markdown file describing your product, key URLs, what agents can do here, and your citation policy. This is what agents actually read.
Content negotiation in middleware
About fifteen lines of server code that check the Accept header on the root URL and serve markdown to ECP agents, HTML to everyone else.
📘Read the official guide
The canonical implementation, including ready-to-paste code for every major stack, lives on the official ECP spec site: endpointcontextprotocol.io/#the-code.
💡See how visible4ai does it
Our own ECP files are live. Inspect them at /ecp.json and /AgentWelcome.md.