Access 1,500+ Murphy's Laws: search, browse by category, random, daily, submit.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste into ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
A comprehensive collection of Murphy's Laws - humorous observations about life's tendency for things to go wrong.
Available on Web, iOS, and Android.
Four official ways to integrate Murphy's Laws. No API key for reads.
| Package | npm | Purpose |
|---|---|---|
murphys-laws-sdk | Typed TypeScript client, zero deps | |
murphys-laws-cli | Command-line interface (npx murphys-laws-cli) | |
murphys-laws-mcp | Model Context Protocol server for AI agents | |
| REST API | - | Public HTTP API at https://murphys-laws.com/api/v1/ |
Full details and examples on the developer landing page.
Public API at https://murphys-laws.com/api/v1/, no auth required for reads.
murphys-laws-sdk on npm is a tiny typed client over the REST API with zero runtime dependencies.
murphys-laws-cli on npm wraps the API for scripts and terminal use.
An MCP server lets AI agents (Claude Desktop, Cursor, VS Code Copilot) query Murphy's Laws directly.
Quick start, no clone needed:
7 tools: search_laws, get_random_law, get_law_of_the_day, get_law, list_categories, get_laws_by_category, submit_law.
See mcp/README.md or npm, or the developer landing page for the full picture.
This is a monorepo containing:
Note: The predev script automatically cleans up any orphaned processes using ports 8787 and 5175 before starting.
If you encounter EADDRINUSE errors (port already in use):
tsx (no JS build step required for startup).backend/src/server/api-server.ts.node --import tsx.shared/modules/*.ts.See Deployment Guide for detailed instructions.
Press ? anywhere on the site to see all available shortcuts:
| Shortcut | Action |
|---|---|
/ | Focus search |
β / β | Navigate search suggestions (when autocomplete is open) |
Enter | Select search suggestion (when autocomplete is open) |
Escape | Close search suggestions / modal / popover |
j | Next law card |
k | Previous law card |
? | Show shortcuts help |
Enter / Space | Activate focused card |
Search Autocomplete: When typing in the search field, suggestions appear automatically. Use arrow keys to navigate, Enter to select, or Escape to close.
git checkout -b feature/amazing-feature)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)This project is licensed under CC0 1.0 Universal (Public Domain).
Thanks to all contributors who have submitted Murphy's Laws over the years!
Made with for anyone who's ever experienced Murphy's Law in action
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/murphys-laws)<a href="https://allmcps.com/mcp/murphys-laws"><img src="https://allmcps.com/api/badge/murphys-laws?style=directory" alt="Murphys Laws on AllMCPs" /></a>