# IFC MCP [Health: Active]

**Category:** 📐 Architecture & Design  
**Repository:** https://github.com/flinker-app/ifc-mcp  
**GitHub Stars:** 12  
**npm Downloads (last month):** 473  
**Views:** 4  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/ifc-mcp

## Description
Local IFC/BIM MCP server with IfcOpenShell Python in Pyodide and an IFC viewer.

## Tools
Capabilities this server exposes over MCP:

- **run-python** — Execute LLM-created Python in the SDK Node/Pyodide IFC runtime.
IFC inputs are mounted only from this call's files array; files listed or open
in the viewer are not automatically available to Python.
Use this tool for IFC inspection, validation, reports, exports, and creating
new IFC files.
For viewer selection, visibility or coloring, generate BCF for set-bcf-view;
Write efficient IfcOpenShell code to get results fast. Inspect unfamiliar APIs before use;

Runtime context: Pyodide uses
the bundled Pyodide 0.28.2 runtime. The package set includes
micropip, ifcopenshell, numpy, pandas, matplotlib, shapely, and
typing-extensions. The Python code is passed directly to the SDK.

Return contract: this tool exposes stdout, stderr, saved_files, uploaded_files,
and any result returned by the raw SDK. Generated files are returned as
temporary localhost download URLs in saved_files. Do not assume files were
written to the user's working directory.
- **open-ifc-viewer** — Open the local IFC viewer if it is not already open. Returns its stable URL to open in a browser or webview. This does not load IFC files or change view state. Use the viewer tools, not browser automation, to interact with the model.
- **show-ifc-file** — Add one IFC file to the already-open local viewer; skip files already loaded. Pass a local IFC/IFCXML/IFCZIP path or a generated IFC download URL from run-python saved_files. Use this for IFC model display only. Returns the same stable viewer URL.
- **clear-ifc-viewer** — Clear the already-open local IFC viewer by removing all loaded IFC files and BCF viewpoint state. This keeps the same stable viewer URL and does not close the browser tab. Use show-ifc-file after this to load a fresh IFC model.
- **set-bcf-view** — Set the view state in the already-open local IFC viewer by applying a BCF/BCFZIP viewpoint file.
Pass either a local BCF/BCFZIP file path or a generated BCF download URL from run Python saved_files.
Apply directly to a loaded model; use show-ifc-file only if the target model is not loaded.
It should not open a new browser tab and should not use browser automation.
Return the application status and issues to the user. Applied, partial and
unconfirmed results finish the action; do not reapply or diagnose warnings.
Retry a failed application only after correcting a concrete reported error.
To generate a BCFZIP with run-python, write a .bcfzip file, then call set-bcf-view with saved_files[0].url:
```python
import ifcopenshell
from bcf.v3 import model as mdl
from bcf.v3.bcfxml import BcfXml
from bcf.v3.visinfo import VisualizationInfoHandler

model = ifcopenshell.open("sample.ifc")
walls = model.by_type("IfcWall")
if walls:
    component = mdl.Component(ifc_guid=walls[0].GlobalId)
    view = VisualizationInfoHandler.create_new(walls[0])
    view.visualization_info.components = mdl.Components(
        selection=mdl.ComponentSelection(component=[component]),
        visibility=mdl.ComponentVisibility(
            default_visibility=False,
            exceptions=mdl.ComponentVisibilityExceptions(component=[component]),
        ),
    )
    bcf = BcfXml.create_new(project_name="IFC MCP")
    topic = bcf.add_topic("Review wall", "Review wall", "ifc-mcp", topic_type="Issue", topic_status="Open")
    topic.add_visinfo_handler(view)
    bcf.save("view.bcfzip")
    print("view.bcfzip")
else:
    print("No walls found.")
```

Second example: color all walls blue and frame the first wall.
BCF colors use RRGGBB or AARRGGBB hex digits without #.
Components.coloring requires a ComponentColoring container, not a plain list;
its color field holds the list of ComponentColoringColor entries.
```python
import ifcopenshell
from bcf.v3 import model as mdl
from bcf.v3.bcfxml import BcfXml
from bcf.v3.visinfo import VisualizationInfoHandler

model = ifcopenshell.open("sample.ifc")
walls = model.by_type("IfcWall")
if walls:
    view = VisualizationInfoHandler.create_new(walls[0])
    view.visualization_info.components = mdl.Components(
        coloring=mdl.ComponentColoring(color=[
            mdl.ComponentColoringColor(
                color="0088FF",
                components=mdl.ComponentColoringColorComponents(
                    component=[mdl.Component(ifc_guid=wall.GlobalId) for wall in walls],
                ),
            ),
        ]),
    )
    bcf = BcfXml.create_new(project_name="IFC MCP")
    topic = bcf.add_topic("Color walls", "Color walls blue", "ifc-mcp", topic_type="Issue", topic_status="Open")
    topic.add_visinfo_handler(view)
    bcf.save("colors.bcfzip")
    print("colors.bcfzip")
else:
    print("No walls found.")
```

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "ifc-mcp": {
    "command": "npx",
    "args": ["-y","ifc-mcp"]
  }
}
```

## Documentation

## What IFC MCP MCP server does

IFC MCP MCP server gives an AI client tools for working with local IFC and BIM files. It can inspect a model, summarize its contents, count entities such as walls, doors, windows, spaces, and property sets, and identify missing names, classifications, or suspicious property values. It can also create a simple IFC file, generate reports such as CSV room-area data, open a model in a local viewer, apply a BCF viewpoint, and clear the viewer.

The server is intended for requests expressed in normal language. Example tasks include asking an assistant to analyze a file, produce an export, create a small building model, or display a selected model. Generated IFC files, reports, and BCF files are exposed through local download links. Viewer requests return a local viewer link when the client does not open it automatically.

## How it works

After installation, the MCP client launches the local server when it needs the available tools. IFC files are read on the local machine. The required IFC operations run in a local Pyodide environment using IfcOpenShell, and the resulting response is sent back to the assistant.

The normal viewer interface includes operations corresponding to opening the viewer, showing an IFC file, applying a BCF view, and clearing the viewer. Applications that already have an IFC viewer can reuse this interface instead of the default local viewer. In that arrangement, the host application supplies handlers for the viewer actions while the MCP client continues to call the same tools.

## Setup and configuration

The documented installation requires Node.js 20 or newer. The server is launched with `npx`, using a standard STDIO configuration such as:

```json
{
  "mcpServers": {
    "ifc-mcp": {
      "command": "npx",
      "args": ["-y", "ifc-mcp"]
    }
  }
}
```

The README provides setup instructions for Claude Desktop, VS Code Copilot, VS Code Codex, and Claude Code in VS Code. Other MCP clients can use the same STDIO server entry when they support that configuration style. No environment variables are required in the documented setup. After changing the configuration, restart the client or begin a new session so it can discover the tools.

For an application with its own viewer, a Node host can create the server and provide callbacks for viewer operations. A browser host can pass selected files and viewer callbacks through the package's browser interface. These custom hosts are responsible for implementing the viewer behavior and returning MCP tool results.

## Tools and capabilities

Supported work includes:

- Inspecting IFC model contents and producing summaries.
- Counting selected IFC element types and property sets.
- Checking for missing names, classifications, and questionable property values.
- Creating simple IFC files with buildings, storeys, and walls.
- Generating reports, including CSV room-area reports.
- Opening IFC files in a viewer and showing selected models.
- Applying BCF viewpoints and clearing the viewer.
- Returning local links for created files and viewer pages.

The exact result depends on the file and the request sent by the AI client. The viewer-related operations can be redirected to an application's existing viewer through custom handlers.

## Limitations and notes

Processing is local, so the server works with file paths available to the local host. Large IFC files can require more than one minute. Cancelling an MCP request does not stop Python code that is already running; wait for the current operation to finish before submitting another request.

IFC MCP MCP server returns local links for generated outputs and viewer actions. If the connected AI application does not open those links automatically, open them in a browser. The documented configuration uses STDIO and does not list required environment variables.

_Full upstream README: https://allmcps.com/mcp/ifc-mcp/readme_

