# MockAPI > MockAPI is a hosted platform for creating mock REST and GraphQL APIs that behave like production. Define or import an API (OpenAPI 3, Swagger 2, Postman, JSON samples or GraphQL types) and MockAPI serves realistic generated data at a stable HTTPS URL, with optional stateful CRUD, latency profiles, per-minute rate limits and named failure scenarios. AI agents can create and manage mocks through MockAPI's MCP server. Free forever plan; paid plans from $4.99/month. Key facts: - REST mock base URL: `https://api.mockapi.com/`; GraphQL: `POST https://graphql.mockapi.com/`. The project is identified by its API key. - Authentication on mock calls: `x-api-key: ` header (recommended), `Authorization: Bearer `, or `?apiKey=` query parameter. - CORS is enabled on every mock endpoint by default. - Scenarios: send `X-MockAPI-Scenario: ` to select a named preset (status, body and delay overrides); otherwise the project's default scenario applies. REST only. - Stateful mode (Developer plan and up): POST creates, GET reads, PUT/PATCH update, DELETE removes. List endpoints accept `page`, `limit` (max 100), `sortBy`, `sortOrder` and any other query key as a field filter. Record ids are UUIDs. - Latency profiles: Fixed, Random, Spike or Slow3G (capped at 10 s). Optional per-project rate limit returns 429 with `X-RateLimit-*` and `Retry-After` headers. - 140+ data types across 60+ locales; models can reference other models. - MCP server: `https://mcp.mockapi.com/api/mcp`. Clients that support OAuth (Claude and ChatGPT connectors, Claude Code, VS Code, Cursor) connect with the plain URL: MockAPI is the authorization server (discovery via `https://mcp.mockapi.com/.well-known/oauth-authorization-server`, dynamic client registration, PKCE) and the user allows access on www.mockapi.com. Alternatively authenticate with `Authorization: Bearer mockapi_mcp_` (key from the dashboard's Connect your AI agent page or Settings → API Keys), or, for clients that only take a URL and can't sign in, use `https://mcp.mockapi.com/api/mcp?key=mockapi_mcp_`. Tools: list_projects, create_project, update_project, get_models_by_project, create_model, update_model, get_rest_endpoints_by_project, create_rest_endpoint, update_rest_endpoint, get_graphql_endpoints_by_project, create_graphql_schema, create_graphql_endpoint, update_graphql_endpoint, import_openapi_schema, import_postman_collection, enable_stateful_mode, disable_stateful_mode, set_scenario, get_request_history, get_simulation_status, generate_test_data, api_design_guide. - Plans (monthly request quota is per project): Free $0 (500 requests/mo, 3 projects, 25 endpoints/project); Developer $4.99/mo (50,000 requests, 25 projects, 100 endpoints, stateful CRUD up to 100 records/model); Team $19.99/mo (200,000 requests, 100 projects, 500 endpoints, 1,000 records/model, custom domains, roles); Business $49.99/mo (1,000,000 requests, 500 projects, unlimited endpoints, 5,000 records/model, management API, priority support). Annual billing saves 20%. Enterprise: contact sales@mockapi.com. ## Docs - [Getting started](https://www.mockapi.com/docs/getting-started): Create an account, a project and your first endpoint, then make your first mock call. - [Projects](https://www.mockapi.com/docs/projects): Projects, API keys, base URLs and settings. - [Data models](https://www.mockapi.com/docs/models): Define models, properties, data types and relationships. - [REST API](https://www.mockapi.com/docs/rest-api): Endpoints, methods, status codes, response models and query parameters. - [GraphQL](https://www.mockapi.com/docs/graphql): Schemas, operations and GraphQL endpoints. - [Data generation](https://www.mockapi.com/docs/data-generation): Built-in generators, locales, regex and static values. - [Authentication](https://www.mockapi.com/docs/authentication): Securing mock endpoints with API keys and Bearer tokens. - [API simulation](https://www.mockapi.com/docs/api-simulation): Stateful mode, scenarios, latency profiles and rate limiting. - [Import & export](https://www.mockapi.com/docs/import-export): OpenAPI, Swagger, Postman and JSON import; project export. - [MCP (AI integration)](https://www.mockapi.com/docs/mcp): Connect Cursor, Claude Code, Claude Desktop and other MCP clients. - [Playground](https://www.mockapi.com/docs/playground): Test REST and GraphQL endpoints in the browser. - [Logs](https://www.mockapi.com/docs/logs): Request logs and activity logs. - [Collaboration](https://www.mockapi.com/docs/collaboration): Team members, roles and permissions. - [Organizations](https://www.mockapi.com/docs/organizations): Organizations, seats and SSO. - [Custom domains](https://www.mockapi.com/docs/custom-domains): Serve mocks from your own domain. - [Plans & billing](https://www.mockapi.com/docs/plans-billing): Plan limits, upgrades and invoices. - [Settings](https://www.mockapi.com/docs/settings): Project, account and API key settings. ## Product - [Homepage](https://www.mockapi.com/): Overview with an interactive stateful mock playground. - [Pricing](https://www.mockapi.com/pricing): Plans and a full feature comparison. - [Model builder demo](https://www.mockapi.com/model-builder-demo): Build a data model and preview generated JSON in the browser, no signup. ## Use cases - [Frontend development](https://www.mockapi.com/solutions/frontend-development) - [API testing & QA](https://www.mockapi.com/solutions/api-testing) - [AI agents (MCP)](https://www.mockapi.com/solutions/ai-agents) - [Mobile development](https://www.mockapi.com/solutions/mobile-development) - [OpenAPI mock server](https://www.mockapi.com/solutions/openapi-mock-server) - [GraphQL mock server](https://www.mockapi.com/solutions/graphql-mock-server) - [Free fake REST API](https://www.mockapi.com/solutions/fake-rest-api) ## Comparisons - [MockAPI vs Postman mock servers](https://www.mockapi.com/compare/postman-mock-server) - [MockAPI vs WireMock](https://www.mockapi.com/compare/wiremock) - [MockAPI vs Mockoon](https://www.mockapi.com/compare/mockoon) - [MockAPI vs json-server](https://www.mockapi.com/compare/json-server) - [MockAPI vs Beeceptor](https://www.mockapi.com/compare/beeceptor) ## Optional - [Full site text for LLMs](https://www.mockapi.com/llms-full.txt) - [Terms of service](https://www.mockapi.com/terms) - [Privacy policy](https://www.mockapi.com/privacy) - [Data processing agreement](https://www.mockapi.com/dpa)