This tutorial will guide you through installing and using HoloViz MCP with Cursor. By the end, you'll have HoloViz MCP running and be able to ask Cursor's AI questions about Panel components!
!!! tip "What you'll learn" - How to install HoloViz MCP - How to configure it with Cursor - How to use it to get help building Panel applications - How to verify everything is working correctly - How to build your first Panel dashboard
!!! note "Prerequisites" Before you begin, ensure you have:
- **Python 3.11 or newer** installed on your system
- **[uv](https://docs.astral.sh/uv/)** package installer
- **Cursor IDE** installed ([Download](https://cursor.sh/))
Open your terminal and install HoloViz MCP as a uv tool:
uv tool install "holoviz-mcp[pydata]"This command installs HoloViz MCP globally, making it available for Cursor to reference.
!!! tip "What's happening?" The uv tool manager creates an isolated environment for HoloViz MCP and installs all necessary dependencies.
The extra `pydata` dependencies are added to install a wide range of python data related packages. We will assume these are installed throughout this guide. You can replace them with your favorite dependencies for your own work.
Install Chromium to enable the holoviz-mcp server to take screenshots:
holoviz-mcp install chromium📦 This downloads 300MB as it downloads the Chromium and FFMPEG engines.
HoloViz MCP needs to index the HoloViz documentation to provide intelligent answers. Run:
holoviz-mcp update index⏱️ This will take 5-10 minutes as it downloads and indexes documentation from Panel, hvPlot, and other HoloViz libraries.
Now let's configure Cursor to use the HoloViz MCP server:
Click the button below to open Cursor's MCP settings:
- Open Cursor Settings
- Navigate to
Features→Model Context Protocol - Click
Add Server - Enter the configuration:
{
"name": "holoviz",
"command": "holoviz-mcp"
}- Save and restart Cursor
Let's verify that HoloViz MCP is working correctly!
Open Cursor's AI chat and try these questions:
Component Discovery:
What Panel components are available for user input?
Component Details:
What parameters does the Panel Button component accept?
If Cursor's AI provides detailed, accurate answers with specific Panel component information, congratulations! HoloViz MCP is working correctly! 🎉
Now that everything is set up, let's build a simple dashboard.
Ask Cursor:
Create a Panel dashboard that displays a slider and shows the square of the slider's value. Save it to app.py
Cursor will provide code using HoloViz MCP's knowledge of Panel components!
Save the code to app.py and run it:
panel serve app.py --showYour dashboard will open in your default web browser!
HoloViz MCP includes a powerful display tool that can render visualizations directly. Ask Cursor:
Use the holoviz_display tool to show me a simple hvplot visualization of random data.
Cursor will use the display tool to generate and display the visualization. See the Display System tutorial for more details.
Cursor is designed for AI-first development. Here are some tips:
- Cmd/Ctrl + K: Open inline AI editor to modify code
- Cmd/Ctrl + L: Open AI chat panel
- @-mentions: Reference files and code in your prompts
- Tab to accept: AI suggestions appear inline as you type
Ask Cursor to help you with Panel-specific tasks, and it will use HoloViz MCP to provide accurate, up-to-date information!
Now that you have HoloViz MCP running with Cursor, explore more:
- Display System: Learn about displaying visualizations
Problem: uv: command not found
Solution: Install uv by following the uv installation guide
Problem: Installation takes too long
Solution: This is normal! The first installation downloads many dependencies. Subsequent updates are much faster.
Problem: Cursor doesn't recognize Panel components
Solution:
- Check that the documentation index completed (Step 3)
- Verify your MCP configuration is correct in Cursor Settings
- Restart Cursor completely
- Try running the server directly:
holoviz-mcp - Check that holoviz-mcp is installed:
holoviz-mcp --version
Problem: MCP server not showing in Cursor
Solution:
- Verify the JSON configuration is correct (no trailing commas)
- Restart Cursor after adding the configuration
- Check Cursor's MCP settings to ensure the server is listed
Problem: MCP server won't connect
Solution:
- Verify Python 3.11+ is installed:
python --version - Check uv installation:
uv --version - Try running the server directly:
holoviz-mcp - Check Cursor's output/console for error messages
For more help, see the Troubleshooting Guide or join the HoloViz Discord.
In this tutorial, you:
✅ Installed HoloViz MCP using uv ✅ Created the documentation index ✅ Installed Chromium ✅ Configured Cursor ✅ Verified the installation ✅ Built your first Panel dashboard ✅ Learned about the display tool ✅ Learned Cursor-specific tips
You're now ready to use HoloViz MCP with Cursor to accelerate your Panel development! Happy coding! 🚀