HTTP Mock Server Config Generator
Define your API routes visually and generate ready-to-use mock server configuration for MSW, json-server, or WireMock. Set methods, paths, status codes, response bodies, and optional delays to simulate slow endpoints.
Frequently Asked Questions
What is MSW (Mock Service Worker)?▼
MSW intercepts network requests at the service worker level in browsers, or using a custom Node server in tests. It lets you mock REST and GraphQL APIs without changing application code. It's the most popular choice for frontend integration tests with React Testing Library or Vitest.
What is json-server?▼
json-server creates a full fake REST API from a JSON file in about 30 seconds. It auto-generates CRUD endpoints for each resource in your db.json. Ideal for rapid prototyping and frontend development when the real backend isn't ready yet.
What is WireMock?▼
WireMock is a flexible API mocking tool available as a standalone server or Java library. It's popular in Java/Spring ecosystems and enterprise environments. It supports request matching by URL, method, headers, and body, as well as response templating and stateful behavior.
When should I use MSW vs json-server?▼
Use MSW for frontend testing (Jest/Vitest + Testing Library) — it intercepts fetch/XHR at the browser level with zero configuration changes. Use json-server for development mocking when you need a quick REST API with CRUD operations accessible from any tool (browser, curl, Postman). Use WireMock for Java/enterprise environments or when you need complex request matching and stateful scenarios.
How do I add a delay to simulate slow APIs?▼
Set the delay field (in milliseconds) on each route. This is useful for testing loading states, skeleton screens, and timeouts in your application. MSW uses the delay() helper from the msw package. json-server supports a global --delay flag. WireMock uses fixedDelayMilliseconds per mapping.
Related Products
on GumroadDevPlaybook Interview Vault
210+ real technical interview questions with model answers, asked at Google, Meta, Amazon, Microsoft, Stripe, and Shopify. Covers Frontend (55), Backend (55), System Design (50), and DSA (50). Available in English and Traditional Chinese.
Buy on Gumroad →TypeScript Quick Reference Toolkit
5 practical reference files for TypeScript developers: cheatsheet, TS vs JS comparison, 20 utility types with real examples, tsconfig best practices template, and 15 common mistakes guide. Print it. Keep it on your desk.
Buy on Gumroad →Developer Interview Vault
210 technical interview questions with model answers, key points, and follow-up questions. Covers Frontend, Backend, System Design, and DSA — bilingual English + Traditional Chinese (ZH-TW). PWYW from $29.
Buy on Gumroad →You Might Also Need
OpenAPI Validator
Paste your OpenAPI 3.x spec (YAML or JSON) to validate structure, find missing required fields, detect duplicate paths, check for missing operationIds, and get errors and warnings with path references.
Open free tool →
API Response Mock Generator
Generate realistic mock API responses with custom status codes, headers, and JSON body. Quick templates for 200, 401, 404, 429, 500 and more. Runs in your browser.
Open free tool →
HTTP Mock Response Builder
Build mock HTTP responses for testing. Set status code, headers, and body — generate curl commands, Jest fetch mocks, and MSW v2 handlers. Runs in your browser.
Open free tool →
More Free Tools
Related Articles
MSW 2.0: The Best Way to Mock APIs in Frontend Tests
A complete guide to Mock Service Worker (MSW) 2.0 — setup, request handlers, Vitest and Jest integration, Storybook mocking, and best practices for realistic API mocking in frontend tests.
API Mocking for Frontend Development: Complete Guide (2025)
How to use API mocking to develop frontend apps without a real backend. Covers MSW, JSON Server, mock services in Postman, browser-based mock APIs, and testing strategies.
API Testing Best Practices 2026: Postman vs Insomnia vs Bruno
Complete guide to API testing in 2026. Compare Postman, Insomnia, and Bruno, learn best practices for REST and GraphQL testing, and build automation pipelines that catch regressions before production.
Visual Regression Testing in 2026: Playwright vs Chromatic vs Percy vs Happo
A comprehensive comparison of visual regression testing tools in 2026. Playwright screenshot tests, Chromatic with Storybook, Percy CI integration, and Happo cross-browser testing — with real code examples, pricing breakdowns, and best practices for flake-free tests.
Vitest vs Jest vs Mocha: Complete Testing Framework Comparison 2026
A comprehensive comparison of Vitest, Jest, and Mocha for JavaScript and TypeScript projects in 2026. Covers speed benchmarks, configuration, TypeScript support, mocking, code coverage, and migration strategies.
Enjoying this tool? Get more like it.
Weekly developer tool guides, productivity playbooks & AI tricks. Free. No spam.
Unlock AI-Powered Dev Tools
- ⚡ AI Code Review, Doc Generator & SQL Builder
- ⚡ All premium templates & early access
- ⚡ Member discounts on Gumroad products
$9/mo after trial · Cancel anytime
Want the full toolkit?
Get DevPlaybook Pro
Every template, guide, boilerplate, and automation script in one bundle. 13 premium products — grab them all at once and save big.
MIT licensed · Instant download · No subscription
See what's included → Browse all deals →