---
title: "Embedding HTML UIs in MCP Servers With Spring AI"
url: https://daily.dev/posts/embedding-html-uis-in-mcp-servers-with-spring-ai-4kuynpwgw
source_url: https://feeds.feedblitz.com/~/957590270/0/baeldung~Embedding-HTML-UIs-in-MCP-Servers-With-Spring-AI
type: article
source: "Baeldung"
published: 2026-05-31T17:37:47.520Z
updated: 2026-05-31T17:38:15.275Z
tags: ["java", "spring-boot", "mcp", "spring-ai"]
reading_time: 7
upvotes: 3
comments: 0
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Embedding HTML UIs in MCP Servers With Spring AI

**[Baeldung](https://daily.dev/sources/baeldung)** · 7 min read · 3 upvotes · 0 comments

## Summary

A step-by-step guide to building an MCP (Model Context Protocol) server with Spring AI and connecting it to Claude Desktop. Covers creating a basic hello-world tool, testing it with MCP Inspector, configuring Claude Desktop via mcp-remote as a stdio-to-HTTP bridge, and then embedding an interactive HTML fortune wheel UI directly inside the chat using @McpTool and @McpResource annotations with Content Security Policy metadata.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://feeds.feedblitz.com/~/957590270/0/baeldung~Embedding-HTML-UIs-in-MCP-Servers-With-Spring-AI>

## Similar posts on daily.dev

- [Blending Chat with Rich UIs with Spring AI and MCP Apps](https://daily.dev/posts/blending-chat-with-rich-uis-with-spring-ai-and-mcp-apps-wgvpjp3mq) · Spring · 2 upvotes · 0 comments

---

Tags: [#java](https://daily.dev/tags/java), [#spring-boot](https://daily.dev/tags/spring-boot), [#mcp](https://daily.dev/tags/mcp), [#spring-ai](https://daily.dev/tags/spring-ai)

[View this post on daily.dev](https://daily.dev/posts/embedding-html-uis-in-mcp-servers-with-spring-ai-4kuynpwgw)
