How to use Mock REST API
- 1
Describe each endpoint
Pick a method, type a path such as /users/:id and choose the status code and an optional delay to imitate a slow network.
- 2
Write the response
Paste fixed JSON, or switch to Fake data and write a template with placeholders like {{fullName}} and a list size.
- 3
Create the mock API
Click Create mock API to get a base URL; every endpoint answers at that URL plus its path, with CORS enabled.
- 4
Call it and iterate
Use Try, curl or fetch from your app, then edit and save — changes apply immediately — or delete the mock when you're done.
Limits and Pro
Free: 10 endpoints per mock API, 100 KB per body and 512 KB in total, delays up to 5 seconds, generated lists up to 100 items, 120 requests a minute per visitor, 10 new mock APIs an hour, deleted after 7 days without requests.
Pro raises the limits to 50 endpoints, 1 MB bodies, 30-second delays and lists of 1,000 items. See Pro
About Mock REST API
Mock REST API gives front-end and mobile developers working endpoints before the real back end exists. Each mock API has its own base URL under /api/mock-api/m/, and every endpoint you define answers there with the method, path, status code, delay, headers and JSON body you chose. Paths can contain parameters, so /users/:id matches /users/7, and a template can echo that value back with {{param(id)}} or read the query string with {{query(name)}}.
Fake data mode turns a JSON template into realistic responses using 36 placeholders, from names, emails, companies and cities to UUIDs, dates, prices, numbers in a range and lorem text. Set a list size to return an array of up to 100 items, and decide whether the data stays the same between requests, which suits snapshot tests, or changes every time. Status codes from 200 to 599 let you rehearse error states such as 401, 404, 429 and 503, and a delay of up to five seconds shows how your loading states behave.
Responses are always JSON with CORS headers, so browsers on any origin can call them. A mock API cannot serve HTML, set cookies or redirect, it does not store the requests it receives, and it is not a database: POST and PUT answer with your configured body without saving anything sent to them.
Privacy
To host your endpoints, the definitions you save — methods, paths, status codes, delays, headers and bodies — are sent to and stored on our server, together with a hashed edit token, the creation and last-request times and a request count. Requests to your endpoints are answered without logging their bodies, headers or IP addresses. A mock API is deleted when you delete it or after 7 days without a request or an edit, and the edit token is kept only in this browser. Anyone with the URL can call your endpoints, so don't put secrets or real personal data in them.
Features
Real HTTPS endpoints
Any method, path parameters, status codes from 200 to 599, delays and custom X- headers.
Fake data templates
Over 30 placeholders for people, companies, places, dates, numbers and text, as one object or a list.
Safe by design
JSON only, CORS on, no request logs, edit token hashed, deleted after 7 days without use.