awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
mswjs avatar

mswjs/msw

0
View on GitHub↗
17,977 stars·612 forks·TypeScript·MIT·25 viewsmswjs.io↗

Msw

MSW is a JavaScript API mocking library and integration testing tool designed to intercept network requests at the network level. It allows for the definition of mock data and status codes using routing syntax to simulate server responses without requiring changes to the application source code.

The project utilizes a service worker to proxy API calls in the browser, providing a mechanism for isolated frontend development and testing. It employs platform-specific network adapters to maintain a consistent mocking interface across both browser and Node.js environments.

The library covers a range of capabilities including request-matching routing, response simulation with custom headers and bodies, and the ability to restrict interception to specific execution contexts to prevent global mock leakage. These features support workflows for isolated component development and the verification of user interface behavior against various API response states.

Features

  • Network and API Mocking - Intercepts outgoing API calls at the network level to return mocked responses without modifying application source code.
  • Frontend API Mocking - Simulates backend responses during development to build and test frontend applications without a live server.
  • Network Request Interceptors - Defines mock data and status codes using routing syntax to simulate server responses at the network level.
  • API Mocking - Allows defining mock data, status codes, and headers using routing syntax to simulate server responses.
  • Interception Logic - Captures outgoing HTTP requests at the browser network layer using a background service worker.
  • Mocking Proxies - Uses Service Workers as a proxy to intercept API calls in the browser for isolated frontend development.
  • Request Interception Middleware - Captures outgoing web requests at the network level to provide mock data without altering application source code.
  • Isolated Component Environments - Supports building and styling UI components in isolation by mocking required external API data.
  • Integration Testing - Simulates backend API behavior to ensure reliable and reproducible integration tests in JavaScript environments.
  • Response Simulators - Constructs synthetic HTTP responses with custom status codes and headers to mimic real server behavior.
  • Frontend Integration Testing - Verifies how a user interface handles various API responses, including error states and edge cases.
  • Network Request Adapters - Abstracts the underlying network layer to provide a consistent mocking interface across browser and Node.js environments.
  • Request Routing - Matches incoming network requests to specific mock handlers using path patterns, HTTP methods, and wildcards.
  • Mocking Tools - Network-level request interception for browser and Node.js.
  • Testing Frameworks - API mocking library for REST and GraphQL.
  • Testing Utilities - Seamless REST/GraphQL API mocking library for browser and Node.js.

Star history

Star history chart for mswjs/mswStar history chart for mswjs/msw

How this analysis was created: This summary and feature list are AI-generated from collected project material and can contain mistakes. Stars, license and language are imported from GitHub. Inclusion does not mean that we have tested or audited this project. Check the source documentation for any feature you depend on. Learn more on our About page.

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Projects sharing features with Msw

These projects share indexed features with Msw. Shared tags can include platform or build tooling; verify the primary use case before treating a result as a replacement.
  • mockoon/mockoonmockoon avatar

    mockoon/mockoon

    8,080View on GitHub↗

    Mockoon is an HTTP API simulation platform and design tool used to create fake API endpoints that simulate server responses without a backend. It functions as an OpenAPI mock server tool and a JSON API mocking utility, allowing for the rapid iteration of API contracts and the generation of response templates. The project distinguishes itself through a combination of stateful mocking, using a local JSON database to simulate CRUD operations, and the ability to run as a headless API mock server via a command line interface. It supports real-time collaborative editing and AI-assisted prototyping

    TypeScriptapiapplicationdesktop
    View on GitHub↗8,080
  • nuysoft/mocknuysoft avatar

    nuysoft/Mock

    19,607View on GitHub↗

    Mock is a JavaScript API mocking tool and network request interceptor designed to decouple front-end development from back-end progress. It functions as an API simulation tool and mock data generator, allowing developers to build user interfaces and high-fidelity prototypes by mimicking the request and response cycle without a live server. The system provides a mechanism for intercepting outgoing HTTP calls and returning simulated data. It enables front-end prototyping by generating synthetic datasets to validate application behavior during automated testing cycles and development. Capabilit

    JavaScript
    View on GitHub↗19,607
  • miragejs/miragejsmiragejs avatar

    miragejs/miragejs

    5,527View on GitHub↗

    Mirage JS is a browser-based mock server and client-side API simulator designed for JavaScript application development. It functions as a mocking tool that intercepts network requests to simulate backend API behavior, allowing developers to build and test frontend interfaces without requiring live backend infrastructure. The tool provides a simulation layer that mimics REST endpoints to facilitate rapid prototyping of user flows and application logic. It enables the creation of fake server responses directly within the web browser to verify how an application handles various data scenarios an

    JavaScript
    View on GitHub↗5,527
  • ctimmerm/axios-mock-adapterctimmerm avatar

    ctimmerm/axios-mock-adapter

    3,544View on GitHub↗

    This library provides a utility for intercepting and simulating HTTP requests within the Axios ecosystem. It functions as an HTTP request interceptor that allows developers to define mock responses for outgoing network traffic, enabling frontend integration testing and development without requiring live backend infrastructure. The tool distinguishes itself by offering granular control over the request lifecycle, including the ability to match specific request patterns and forward unmatched traffic to actual destinations. It supports the simulation of unstable network environments by injecting

    JavaScriptaxiosjavascriptmock
    View on GitHub↗3,544
Compare all 30 related projects→

Frequently asked questions

What does mswjs/msw do?

MSW is a JavaScript API mocking library and integration testing tool designed to intercept network requests at the network level. It allows for the definition of mock data and status codes using routing syntax to simulate server responses without requiring changes to the application source code.

What are the main features of mswjs/msw?

The main features of mswjs/msw are: Network and API Mocking, Frontend API Mocking, Network Request Interceptors, API Mocking, Interception Logic, Mocking Proxies, Request Interception Middleware, Isolated Component Environments.

Which projects share features with mswjs/msw?

Projects with overlapping indexed features include: mockoon/mockoon — Mockoon is an HTTP API simulation platform and design tool used to create fake API endpoints that simulate server… nuysoft/mock — Mock is a JavaScript API mocking tool and network request interceptor designed to decouple front-end development from… miragejs/miragejs — Mirage JS is a browser-based mock server and client-side API simulator designed for JavaScript application… ctimmerm/axios-mock-adapter — This library provides a utility for intercepting and simulating HTTP requests within the Axios ecosystem. It functions… typicode/jsonplaceholder — JSONPlaceholder is a REST API mock server and JSON mocking service that provides a hosted frontend development… axios/axios — Axios is an isomorphic, promise-based HTTP client designed for making asynchronous network requests across different…