json-server
A command-line tool that turns a JSON file into a fake REST API for prototyping.
These buttons open the developer's own site, repository or store listing in a new tab. wares.gg does not host downloads.
About json-server
json-server reads a JSON file and serves it as a REST API, so a front-end developer can build and test against realistic endpoints before a real back end exists. It is installed from npm and started from the command line, with no code to write for basic use.
The current main branch documents a v1 beta that is usable but may bring breaking changes. The stable version has its own separate documentation.
Strengths
- Mock REST API from a single JSON file
- No code needed for basic use
- Installed with one npm command
- Widely used, with a large user base
Limitations
- v1 is in beta and may bring breaking changes
- Requires Node.js and npm
- Meant for prototyping and testing, not production
Details
- Pricing
- FreeFree to install from npm.
- License
- Proprietary
- Developer
- typicode
- Platforms
- Windows, macOS, Linux, Command line
- How it runs
- Downloadable app
- Account
- Not required
- Works offline
- Yes
- Best suited for
- Front-end developers who need a quick mock back end
- Categories
- API clients, Developer tools
- Last verified
- Added
- Provenance
- Facts checked against the developer's own pages and store listings, 1 sources on file.
Alternatives to json-server
Compare allSoftware that can replace json-server for an important use case, and what changes if you switch.
Mockoon
A desktop app and CLI for designing and running mock REST APIs locally without an account.
Mockoon offers a desktop app plus CLI for designing local mock REST APIs, imports OpenAPI specifications and records requests, and is open source instead of a JSON-file-only tool.
WireMock
An open-source tool for mocking HTTP APIs so you can test without real service dependencies.
WireMock adds flexible request matching, response templating, record and playback, and fault simulation, but standalone mode needs Java or Docker rather than Node.js.
Prism
An open-source mock server and validation proxy built from OpenAPI documents and Postman collections.
Prism generates a mock server directly from an OpenAPI file or Postman collection and adds a validation proxy, but depends on having a complete, accurate specification.
MockServer
An open-source self-hosted server for mocking, proxying and recording HTTP, HTTPS and gRPC APIs.
MockServer is an open-source self-hosted server that mocks and proxies HTTP and gRPC, records traffic and injects faults, starting with one Docker command.
Beeceptor
A web service for creating mock API servers and inspecting incoming webhook requests in real time.
Beeceptor moves mocking to a hosted service on a unique subdomain with no setup and live request inspection, but requests pass through a third party and advanced features are paid.
Mockbin
A free web tool that creates mock API endpoints with fixed responses and logs requests to them.
Mockbin is a free open-source web tool for mock endpoints with fixed responses and request logging, needing no install, but without programmable logic or a data-backed REST API.
Similar software
Related functionality, not necessarily a direct replacement.
Postman
The most widely used API client, for sending HTTP requests, organising them into collections and sharing them with a team.
Stoplight
A web platform for designing OpenAPI descriptions, generating API documentation and running mock servers.
Apidog
An API platform for designing, debugging, mocking and testing APIs, with desktop and web clients.
PutsReq
A web tool that records incoming HTTP requests and returns fake responses you define in JavaScript.