Run a blazing fast mock server in just seconds! 🚀

All you need is to make a json file that contains path and response mapping. See an example here.

Only json is supported for now, please create issues for bugs and new features.


With defaults -


Defaults: addr=localhost:7070 , file=mock.json

With custom flags -


For windows -


Sample mock.json file

  "<YOUR_PATH>": {
    "statusCode": <INTEGER>,
    "responseBody": {

These paths will be matched and the json will be sent.

Example -

  "/hello/worlds": {
    "statusCode": 200,
    "responseBody": {
      "message": "Hello worlds!",
      "data" : {
        "time": "now"
      "worlds": [
        "cross origin world",
        "mars world",
        "moon world"

If a request lands in the server in path /hello/worlds the json object inside responseBody will be sent as response.

The request type [POST or GET] doesn't matter.


For mac/linux -

go mod download
go build

For windows -

go mod download
GOOS=windows GOARCH=amd64 go build 

**If the build/binary doesn't work for you, you can do this -

  • Check your os and arch using this command - go env GOOS GOARCH
  • Use the output os and arch to build the binary - GOOS=<YOUR_OS> GOARCH=<YOUR_ARCH> go build