A PhoticLabs product.
MimicServer is a local-first API mocking engine and gateway for developers.
Define mock routes (organized into groups), serve JSON responses instantly with
path-parameter support (/api/user/:id), and inspect live traffic —
all from a fast, native desktop app with zero cloud dependency.
| Problem | MimicServer's Answer |
|---|---|
| Mock platforms require internet | Runs 100% locally — no account, no cloud |
| Electron apps are heavy and slow | Native Rust binary — < 15MB, instant startup |
| JSON config files break silently | SQLite — relational, transactional, crash-safe |
| Server restarts drop in-flight requests | Hot reload via Arc<RwLock<>> — zero downtime |
| Traffic is invisible during development | Built-in traffic log — every request recorded |
- Mock any HTTP endpoint — define method, path, status code, and a
.jsonresponse file - Path-parameter support — use
:idsegments in paths (/api/user/:id) - Organize routes in groups — logical folders for your API endpoints
- Instant hot reload — save a route and it is live immediately, no server restart
- Traffic log — see every request: method, status, URL, latency, timestamp
- Port & prefix configuration — run on any port and/or behind a global prefix via the settings panel
- Light/Dark theme — toggle between themes in settings
- Health endpoint —
GET /healthalways available to confirm the server is alive - Cross-platform — single binary for Windows, macOS, and Linux
- Branded UI — dark, professional developer-tool aesthetic built on the PhoticLabs design system
| Layer | Choice |
|---|---|
| UI | egui + eframe |
| Design System | pl-components (PhotoicLabs internal crate) |
| Async Runtime | Tokio |
| HTTP | Axum + Hyper |
| Database | SQLite via rusqlite (WAL mode, foreign keys) |
| Payload Storage | Raw .json files on disk |
- No request header inspection — ignored
- No response templating — static
.jsonfiles only - No authentication on the mock server
- No cloud sync — local-first, always
- Rust 1.75 or later
- Cargo (included with Rust)
# Clone the repository
git clone https://github.com/Photic-Labs/mimic-server.git
cd mimic-server
# Run in development mode
cargo run
# Build release binary
cargo build --releaseThe app opens a native window.
The database is created automatically on first run in your platform's data directory:
- macOS:
~/Library/Application Support/MimicServer/mimic_server_v1.db - Linux:
~/.local/share/MimicServer/mimic_server_v1.db - Windows:
C:\Users\<USER>\AppData\Roaming\MimicServer\mimic_server_v1.db
- Open the app
- Click ▶ Start Server in the top bar
- The server binds to
localhost:8080by default - Add an API group in the sidebar, then add routes inside it
- Select a route to edit — set method, path (supports
:idparams), status code, and a.jsonfile - Hit the endpoint from your app or
curl - Watch the request appear in the Traffic Log panel
# Confirm the server is alive
curl http://localhost:8080/health
# Hit a configured mock route
curl http://localhost:8080/api/your-routePort and API prefix are stored in the app_config SQLite table.
Default port: 8080. Default prefix: empty.
Change them in the Settings panel — takes effect on next server start.
The global prefix applies to all routes. For example, with prefix /api/v1,
a route at /users is served at /api/v1/users.
Each route points to a .json file on disk.
The file is read fresh on every request — edit it externally and the next request picks up the change immediately.
{
"id": 1,
"name": "John Doe",
"email": "johndoe@annonymus.com"
}If the file is missing or contains invalid JSON, MimicServer responds 500 with a descriptive error body instead of crashing.
Every matched route returns these headers:
Content-Type: application/json
X-Mimic-Route-Id: <route_id>
X-Mimic-Latency-Ms: <latency>
X-Powered-By: MimicServer
| Scenario | Status | Error Code |
|---|---|---|
Route matched, .json file missing |
500 |
response_file_not_found |
| Route matched, file is invalid JSON | 500 |
invalid_json_file |
| Route matched, no file configured | 501 |
no_response_file_configured |
| No matching route (not even pattern) | 404 |
route_not_found |
Download the latest version for your operating system from the Releases Page.
Because MimicServer is an independent open-source project built entirely locally, the binaries are currently self-signed. On modern macOS (Apple Silicon/Intel), Gatekeeper will block the application on first launch with a "Move to trash" or "Unidentified developer" warning.
To bypass this and run the app natively:
- Drag Mimic Server.app into your
/Applicationsfolder. - Open your terminal and run the following command to clear the macOS quarantine flag:
xattr -cr "/Applications/Mimic Server.app"
GNU General Public License v3.0 © PhoticLabs
See LICENSE for the full text.

