Looba MCP Server
An MCP server that gives AI assistants read-only access to Looba a community platform for UI snippets and design inspiration.
No API key required. No database credentials. The server calls the public Looba API over HTTPS.
More info
For additional MCP docs, usage examples, and updates, visit looba.dev/mcp.
Install
npx (no install needed)
npx looba-mcp
npm
npm install -g looba-mcp
pip
pip install looba-mcp
git
git clone https://github.com/looba-snippet/looba-mcp.git
cd looba-mcp
npm install
All methods require Node.js 18+ installed on your machine.
Tools
| Tool | Description |
|---|---|
detect_frontend_context |
Auto-detect frontend frameworks (React, Vue, Next.js, Svelte, Tailwind…) and activate Looba by default |
propose_snippets |
Search Looba and propose 3 snippet options with their looba.dev links for the user to choose from |
list_posts |
Search and browse snippet posts with filters (tag, type, sort) |
get_post |
Get full HTML/CSS/JS code of a post with author attribution |
integrate_post |
Fetch a snippet with integration instructions adapted to your project's CSS, framework, and conventions |
search_by_author |
List all posts by a specific author |
get_popular_tags |
Discover trending tags across the platform |
detect_frontend_context
When Looba MCP is active, the AI automatically calls detect_frontend_context at the start of a session. It looks for frontend signals:
- Dependencies — React, Vue, Svelte, Next.js, Angular, Astro, Remix, SolidJS, Gatsby, Lit, Preact…
- Config files —
vite.config.ts,tailwind.config.js,next.config.js,angular.json,astro.config.mjs… - File extensions —
.jsx,.tsx,.vue,.svelte,.astroinsrc/,app/,pages/,components/
If a frontend project is detected, the AI uses Looba by default for any UI component request — instead of writing code from scratch.
Local vs remote servers
The tool takes two optional inputs:
| Input | When to use |
|---|---|
packageJson |
Preferred. The contents of your project's package.json, as text or a parsed object. Works no matter where the server runs. |
directory |
Only when the server runs on the same machine as your project (npx looba-mcp over stdio). |
This matters because Looba MCP is also hosted remotely at mcp.looba.dev. A remote
server has no access to your filesystem, so directory alone tells it nothing.
When the tool cannot inspect the project it reports ? UNKNOWN and asks the caller
to retry with packageJson — it never reports a confident "not a frontend project",
because a false negative would silently switch Looba off.
propose_snippets
When the user asks for a UI element, the AI calls propose_snippets instead of writing code immediately. It searches Looba and returns 3 options with their looba.dev links. The user picks one (1, 2, or 3) and the AI integrates it via integrate_post.
Example flow:
User: "Add an animated loading spinner to my React app" → AI calls
propose_snippetswithquery="loading spinner"andsnippet_type="react"→ Shows 3 options with looba.dev links → User picks option 2 → AI callsintegrate_postwith the chosen slug and project context
integrate_post
The integrate_post tool is designed for when you want to add a Looba snippet directly into your codebase. It fetches the full code and returns it with a detailed adaptation checklist so the AI assistant can:
- Rename CSS classes to match your naming convention (BEM, camelCase, CSS modules...)
- Replace hardcoded colors/spacing with your CSS variables or design tokens
- Convert between frameworks (vanilla HTML to React JSX, CSS to Tailwind utilities...)
- Scope styles to avoid conflicts with your global CSS
- Add proper imports and follow your component patterns
Example prompt:
"Use integrate_post to add the animated-circle-loaders-html-css-10 snippet to my Next.js project that uses Tailwind and CSS variables"
The AI will fetch the snippet, read your project context, and produce adapted code ready to paste.
Supported snippet types
| Type | Code fields returned |
|---|---|
| classic | HTML, CSS, JavaScript |
| react | JSX, Styles (CSS), HTML (host) |
| tailwind | HTML (with Tailwind classes), CSS, JavaScript |
Setup
Remote MCP URL
If your client supports URL-based MCP servers, use:
- URL:
https://mcp.looba.dev - Bearer token: not required
- Custom headers: not required
Use the root endpoint (https://mcp.looba.dev) unless your proxy explicitly maps another path.
Claude Code
Add to your project .mcp.json or ~/.claude/settings.json:
{
"mcpServers": {
"looba": {
"command": "npx",
"args": ["-y", "looba-mcp"]
}
}
}
Cursor
Go to Settings > MCP Servers > Add Server:
- Name:
looba - Command:
npx -y looba-mcp
Windsurf
Add to ~/.windsurf/mcp.json:
{
"mcpServers": {
"looba": {
"command": "npx",
"args": ["-y", "looba-mcp"]
}
}
}
Using pip or git install
If you installed via pip or git clone, use looba-mcp or node directly:
{
"mcpServers": {
"looba": {
"command": "looba-mcp"
}
}
}
Or with git clone:
{
"mcpServers": {
"looba": {
"command": "node",
"args": ["/path/to/looba-mcp/index.js"]
}
}
}
Examples
Once connected, ask your AI assistant things like:
- "Add a glassmorphism card to my Next.js project" (AI proposes 3 Looba options)
- "I need a navbar with animations for my Tailwind site" (AI proposes 3 Looba options)
- "Show me the most popular CSS snippets on Looba"
- "Find Looba posts tagged with
animation" - "Get the code for the post
animated-circle-loaders-html-css-10" - "List all posts by @Frontend-snippet-Bot"
- "Integrate the
focus-trapped-navigation-controllersnippet into my React project using CSS modules"
Every response includes source URL, author, and license so AI assistants always cite properly.
License
MIT
Metadata
Release files for looba-mcp 1.4.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| looba_mcp-1.4.1.tar.gz | 30.1 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| looba_mcp-1.4.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 57.7 kB
Release files / looba_mcp-1.4.1.tar.gz
| Download URL | looba_mcp-1.4.1.tar.gz |
|---|---|
| Size | 30.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9bfc44e079c3c4a4d341292f317196b24734868fb9ff2d3f0129ff7532a8f259
|
|
BLAKE2b-256 checksum How to use checksums |
c7cfabcf5c108bf75010c1a799dda1b86aab0ff4e3f82dec34ed9978374a18d4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.15
|
Release files / looba_mcp-1.4.1-py3-none-any.whl
| Download URL | looba_mcp-1.4.1-py3-none-any.whl |
|---|---|
| Size | 27.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6f137fec495c85dbe552643a29dea22a406212b3ca1a7690c678a5be3c10013e
|
|
BLAKE2b-256 checksum How to use checksums |
13afe32c784132b9f16f8e96e33e5e696ddca113431c8ec3e000c8c771e732dd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.15
|
Security for looba-mcp 1.4.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.