diff --git a/pygittools-mcp/src/pygittools_mcp/exceptions.py b/pygittools-mcp/src/pygittools_mcp/exceptions.py
index 390ef73..c810b08 100644
--- a/pygittools-mcp/src/pygittools_mcp/exceptions.py
+++ b/pygittools-mcp/src/pygittools_mcp/exceptions.py
@@ -20,6 +20,12 @@ class CommentNotFoundError(ToolError):
         super().__init__(f"Comment {comment_oid} not found")
 
 
+class MergeRequestNotFoundError(ToolError):
+    def __init__(self, mr_ref: str):
+        self.mr_ref = mr_ref
+        super().__init__(f"Merge request {mr_ref} not found")
+
+
 class InvalidTaskStatusError(ToolError):
     def __init__(self, value: str):
         self.value = value
diff --git a/pygittools-mcp/src/pygittools_mcp/mcp_server.py b/pygittools-mcp/src/pygittools_mcp/mcp_server.py
index dffa386..9678f86 100644
--- a/pygittools-mcp/src/pygittools_mcp/mcp_server.py
+++ b/pygittools-mcp/src/pygittools_mcp/mcp_server.py
@@ -32,6 +32,7 @@ from pygittools_mcp.exceptions import (
     InvalidTaskDueDateError,
     InvalidTaskPriorityError,
     InvalidTaskStatusError,
+    MergeRequestNotFoundError,
     TaskNotFoundError,
 )
 from pygittools_mcp.models import CreateTaskToolResult
@@ -90,14 +91,19 @@ def get_task_tool(task_ref: str, project: str | None = None) -> TaskView:
 @mcp.tool(title="List comments")
 def list_comments_tool(
     task_ref: str | None = None,
+    mr_ref: str | None = None,
     project: str | None = None,
 ) -> list[CommentView]:
-    """List comments from refs/tags/comments/, or only those on a task when task_ref is set."""
+    """List comments from refs/tags/comments/, or only those on a task/MR when a ref is set."""
+    if task_ref is not None and mr_ref is not None:
+        raise ValueError("Provide task_ref or mr_ref, not both")
     location = _repo_for_tool(project)
     repo = open_repository(location)
     try:
-        return list_comments(repo, task_ref)
+        return list_comments(repo, task_id=task_ref, mr_ref=mr_ref)
     except KeyError as exc:
+        if mr_ref is not None:
+            raise MergeRequestNotFoundError(mr_ref) from exc
         if task_ref is None:
             raise
         raise TaskNotFoundError(task_ref) from exc
diff --git a/pygittools-mcp/src/pygittools_mcp/mcp_test.py b/pygittools-mcp/src/pygittools_mcp/mcp_test.py
index 57c33df..3bd5339 100644
--- a/pygittools-mcp/src/pygittools_mcp/mcp_test.py
+++ b/pygittools-mcp/src/pygittools_mcp/mcp_test.py
@@ -8,7 +8,8 @@ from typing import Any
 
 import pytest
 from mcp import Client as MCPClient
-from pygit2 import Oid, Repository, init_repository
+from pygit2 import Oid, Repository, Signature, init_repository
+from pygittools.merge import MR_REF_PREFIX, MergeRequest, create_mr_comment
 from pygittools.tasks import (
     EMPTY_TREE_OID_HEX,
     Board,
@@ -26,6 +27,7 @@ from pygittools_mcp.exceptions import (
     InvalidTaskDueDateError,
     InvalidTaskPriorityError,
     InvalidTaskStatusError,
+    MergeRequestNotFoundError,
 )
 from pygittools_mcp.mcp_server import mcp
 from pygittools_mcp.models import CreateTaskToolResult
@@ -186,6 +188,29 @@ async def test_get_comment_tool_not_found(mcp_client: MCPClient) -> None:
 
 
 @pytest.mark.anyio
+async def test_list_comments_tool_by_mr_ref(mcp_client: MCPClient, repo: Repository) -> None:
+    sig = Signature("alice", "alice@example.com")
+    tb = repo.TreeBuilder()
+    tree = tb.write()
+    commit = repo.create_commit(None, sig, sig, "mr tip", tree, [])
+    mr_ref = f"{MR_REF_PREFIX}mcpcomments000001"
+    mr = MergeRequest(commit, sig, ours="refs/heads/main", title="MR", name=mr_ref)
+    mr.write(repo)
+    created = create_mr_comment(repo, mr_ref, "on the mr", tagger=TAGGER)
+
+    listed = await mcp_client.call_tool("list_comments_tool", {"mr_ref": mr_ref})
+    assert not listed.is_error, listed.content
+    comments = listed.structured_content["result"]
+    assert len(comments) == 1
+    assert comments[0]["oid"] == str(created["oid"])
+    assert comments[0]["content"] == "on the mr"
+
+    missing = await mcp_client.call_tool("list_comments_tool", {"mr_ref": "missing"})
+    assert missing.is_error
+    assert str(MergeRequestNotFoundError("missing")) in missing.content[0].text
+
+
+@pytest.mark.anyio
 async def test_create_task_tool_success(mcp_client: MCPClient) -> None:
     title = "Test Task"
     description = "A test task"
diff --git a/pygittools/README.md b/pygittools/README.md
index 4d5dbae..3e350ea 100644
--- a/pygittools/README.md
+++ b/pygittools/README.md
@@ -54,6 +54,7 @@ Cursor project config (`.cursor/mcp.json`):
 ```
 
 Tools: `list_boards_tool`, `list_tasks_tool`, `get_task_tool`, `create_task_tool`,
-`list_comments_tool`, `get_comment_tool`, `board_by_status_tool`.
+`list_comments_tool` (optional `task_ref` or `mr_ref`), `get_comment_tool`,
+`board_by_status_tool`.
 Resources: `board://{board_name}`, `task://{task_ref}`, `comment://{comment_oid}`.
 
diff --git a/pygittools/src/pygittools/merge.py b/pygittools/src/pygittools/merge.py
index a28984e..e188553 100644
--- a/pygittools/src/pygittools/merge.py
+++ b/pygittools/src/pygittools/merge.py
@@ -12,7 +12,14 @@ from typing import Any, TypedDict
 from pygit2 import Commit, GitError, Oid, Repository, Signature, Tag, reference_is_valid_name
 from pygit2.enums import MergeAnalysis
 
-from pygittools.tasks import GIT_OBJECT_TAG, _build_tag_raw, _DateTimeEncoder
+from pygittools.tasks import (
+    GIT_OBJECT_TAG,
+    Comment,
+    _as_oid,
+    _build_tag_raw,
+    _DateTimeEncoder,
+    get_comment,
+)
 
 MR_REF_PREFIX: str = "refs/tags/mr/"
 
@@ -263,6 +270,112 @@ def get_merge_request_by_oid(repo: Repository, oid: Oid) -> MergeRequest:
     return _merge_request_from_tag(obj)
 
 
+def _normalize_mr_ref(mr_ref: str) -> str:
+    if mr_ref.startswith("refs/"):
+        return mr_ref
+    if mr_ref.startswith("mr/"):
+        return f"refs/tags/{mr_ref}"
+    return f"{MR_REF_PREFIX}{mr_ref}"
+
+
+def _rewrite_mr_comments(repo: Repository, mr_ref: str, comments: list[Oid | str]) -> Oid:
+    ref = _normalize_mr_ref(mr_ref)
+    try:
+        mr = get_merge_request(repo, ref)
+    except (KeyError, ValueError) as exc:
+        raise KeyError(f"Merge request not found: {ref}") from exc
+    mr.comments = comments
+    mr.update_message()
+    return mr.write(repo)
+
+
+class CreateMrCommentResult(TypedDict, total=True):
+    oid: Oid
+    comment: Comment
+    mr_oid: Oid
+
+
+class ModifyMrCommentResult(TypedDict, total=True):
+    oid: Oid
+    comment: Comment
+    mr_oid: Oid
+
+
+def create_mr_comment(
+    repo: Repository,
+    mr_ref: str,
+    content: str,
+    *,
+    tagger: str = "",
+) -> CreateMrCommentResult:
+    """Write a comment, append it to the merge request, and rewrite the MR tag."""
+    ref = _normalize_mr_ref(mr_ref)
+    try:
+        mr = get_merge_request(repo, ref)
+        target_oid = repo.references[ref].resolve().target
+    except (KeyError, ValueError) as exc:
+        raise KeyError(f"Merge request not found: {ref}") from exc
+    comment = Comment(target=target_oid, tagger=tagger, content=content)
+    comment_oid = comment.write(repo)
+    comments = list(mr.comments or [])
+    comments.append(str(comment_oid))
+    mr_oid = _rewrite_mr_comments(repo, ref, comments)
+    return {"oid": comment_oid, "comment": comment, "mr_oid": mr_oid}
+
+
+def modify_mr_comment(
+    repo: Repository,
+    comment_oid: Oid | str,
+    content: str,
+    *,
+    mr_ref: str,
+) -> ModifyMrCommentResult:
+    """Rewrite comment content and replace its OID in the MR's comment list."""
+    old_oid = _as_oid(comment_oid)
+    old_hex = str(old_oid)
+    comment = get_comment(repo, old_oid)
+    ref = _normalize_mr_ref(mr_ref)
+    try:
+        mr = get_merge_request(repo, ref)
+    except (KeyError, ValueError) as exc:
+        raise KeyError(f"Merge request not found: {ref}") from exc
+    comments = list(mr.comments or [])
+    if old_hex not in {str(entry) for entry in comments}:
+        raise KeyError(f"Comment {old_hex} is not linked to merge request {ref}")
+    comment.content = content
+    comment.edited_at = datetime.now(UTC)
+    comment.update_message()
+    new_oid = comment.write(repo)
+    updated = [str(new_oid) if str(entry) == old_hex else entry for entry in comments]
+    mr_oid = _rewrite_mr_comments(repo, ref, updated)
+    return {"oid": new_oid, "comment": comment, "mr_oid": mr_oid}
+
+
+def delete_mr_comment(
+    repo: Repository,
+    comment_oid: Oid | str,
+    *,
+    mr_ref: str,
+) -> Oid:
+    """Unlink a comment from its MR, delete the comment ref, return the new MR OID."""
+    oid = _as_oid(comment_oid)
+    oid_hex = str(oid)
+    comment = get_comment(repo, oid)
+    ref = _normalize_mr_ref(mr_ref)
+    try:
+        mr = get_merge_request(repo, ref)
+    except (KeyError, ValueError) as exc:
+        raise KeyError(f"Merge request not found: {ref}") from exc
+    comments = list(mr.comments or [])
+    if oid_hex not in {str(entry) for entry in comments}:
+        raise KeyError(f"Comment {oid_hex} is not linked to merge request {ref}")
+    remaining = [entry for entry in comments if str(entry) != oid_hex]
+    mr_oid = _rewrite_mr_comments(repo, ref, remaining)
+    if comment.name in repo.references:
+        repo.references.delete(comment.name)
+    return mr_oid
+
+
 def try_merge_request_from_tag(repo: Repository, tag: Tag) -> MergeRequest | None:
     try:
         return get_merge_request_by_oid(repo, tag.id)
diff --git a/pygittools/src/pygittools/merge_test.py b/pygittools/src/pygittools/merge_test.py
index abf67c1..eb6c4b6 100644
--- a/pygittools/src/pygittools/merge_test.py
+++ b/pygittools/src/pygittools/merge_test.py
@@ -8,15 +8,18 @@ from pygittools.merge import (
     MergeRequest,
     MergeRequestStatus,
     assert_merge_head_object,
+    create_mr_comment,
+    delete_mr_comment,
     generate_mr_ref,
     get_merge_request,
     get_merge_request_by_oid,
     merge_request_status_fields,
+    modify_mr_comment,
     peel_mr_head_to_commit_oid,
     resolve_merge_request_tag_to_tip,
     try_merge_request_from_tag,
 )
-from pygittools.tasks import EMPTY_TREE_OID_HEX, _ensure_empty_tree
+from pygittools.tasks import COMMENT_REF_PREFIX, EMPTY_TREE_OID_HEX, Comment, _ensure_empty_tree, get_comment
 
 SIG = Signature("alice", "alice@example.com")
 
@@ -219,3 +222,55 @@ def test_merge_request_status_fields_can_fast_forward(repo: Repository) -> None:
     assert fields["status_label"] == "Can fast-forward"
     assert fields["show_merge_button"] is True
     assert fields["status_detail"] == ""
+
+
+def _seed_mr(repo: Repository, suffix: str = "commentseed00001") -> str:
+    c = _commit(repo)
+    ref = f"{MR_REF_PREFIX}{suffix}"
+    mr = MergeRequest(c, SIG, ours="refs/heads/main", title="Discuss", name=ref)
+    mr.write(repo)
+    repo.create_reference("refs/heads/main", c, force=True)
+    return ref
+
+
+def test_create_mr_comment_links_mr(repo: Repository) -> None:
+    ref = _seed_mr(repo)
+    result = create_mr_comment(repo, ref, "hello", tagger="bob <bob@example.com>")
+    loaded = get_comment(repo, result["oid"])
+    assert loaded.content == "hello"
+    assert loaded.tagger == "bob <bob@example.com>"
+    mr = get_merge_request(repo, ref)
+    assert mr.comments == [str(result["oid"])]
+    assert str(repo.references[ref].resolve().target) == str(result["mr_oid"])
+
+
+def test_modify_mr_comment_replaces_oid(repo: Repository) -> None:
+    ref = _seed_mr(repo, "commentseed00002")
+    created = create_mr_comment(repo, ref, "before", tagger="alice <alice@example.com>")
+    modified = modify_mr_comment(repo, created["oid"], "after", mr_ref=ref)
+    assert str(modified["oid"]) != str(created["oid"])
+    assert get_comment(repo, modified["oid"]).content == "after"
+    mr = get_merge_request(repo, ref)
+    assert mr.comments == [str(modified["oid"])]
+
+
+def test_modify_mr_comment_rejects_unlinked_oid(repo: Repository) -> None:
+    ref = _seed_mr(repo, "commentseed00003")
+    create_mr_comment(repo, ref, "on mr", tagger="alice <alice@example.com>")
+    mr_oid = repo.references[ref].resolve().target
+    orphan = Comment(mr_oid, "alice <alice@example.com>", "orphan")
+    orphan_oid = orphan.write(repo)
+    with pytest.raises(KeyError, match="not linked"):
+        modify_mr_comment(repo, orphan_oid, "nope", mr_ref=ref)
+
+
+def test_delete_mr_comment_unlinks_and_removes_ref(repo: Repository) -> None:
+    ref = _seed_mr(repo, "commentseed00004")
+    created = create_mr_comment(repo, ref, "bye", tagger="alice <alice@example.com>")
+    comment_ref = get_comment(repo, created["oid"]).name
+    assert comment_ref.startswith(COMMENT_REF_PREFIX)
+    new_mr_oid = delete_mr_comment(repo, created["oid"], mr_ref=ref)
+    mr = get_merge_request(repo, ref)
+    assert mr.comments == []
+    assert comment_ref not in repo.references
+    assert str(repo.references[ref].resolve().target) == str(new_mr_oid)
diff --git a/pygittools/src/pygittools/tasks_query.py b/pygittools/src/pygittools/tasks_query.py
index e96d3b3..c02d694 100644
--- a/pygittools/src/pygittools/tasks_query.py
+++ b/pygittools/src/pygittools/tasks_query.py
@@ -9,6 +9,7 @@ from typing import TypedDict
 
 from pygit2 import Oid, Repository
 
+from pygittools.merge import MR_REF_PREFIX, get_merge_request
 from pygittools.tasks import (
     BOARD_REF_PREFIX,
     COMMENT_REF_PREFIX,
@@ -125,9 +126,9 @@ def _comment_to_view(comment: Comment, oid: Oid | str) -> CommentView:
     }
 
 
-def _load_task_comments(repo: Repository, task: Task) -> list[CommentView]:
+def _comments_from_oids(repo: Repository, comment_oids: list[Oid | str]) -> list[CommentView]:
     comments: list[CommentView] = []
-    for oid_hex in getattr(task, "comments", []) or []:
+    for oid_hex in comment_oids:
         try:
             oid = Oid(hex=oid_hex) if isinstance(oid_hex, str) else oid_hex
             comment = get_comment(repo, oid)
@@ -138,6 +139,18 @@ def _load_task_comments(repo: Repository, task: Task) -> list[CommentView]:
     return comments
 
 
+def _load_task_comments(repo: Repository, task: Task) -> list[CommentView]:
+    return _comments_from_oids(repo, list(getattr(task, "comments", []) or []))
+
+
+def _normalize_mr_ref_for_query(mr_ref: str) -> str:
+    if mr_ref.startswith("refs/"):
+        return mr_ref
+    if mr_ref.startswith("mr/"):
+        return f"refs/tags/{mr_ref}"
+    return f"{MR_REF_PREFIX}{mr_ref}"
+
+
 def _task_to_view(task: Task, *, comments: list[CommentView] | None = None) -> TaskView:
     view: TaskView = {
         "ref": task.name,
@@ -242,8 +255,14 @@ def get_comment_view(repo: Repository, comment_oid: str) -> CommentView:
     return _comment_to_view(comment, oid)
 
 
-def list_comments(repo: Repository, task_id: str | None = None) -> list[CommentView]:
-    """List comments from comment refs, or only those linked to a task when given."""
+def list_comments(
+    repo: Repository,
+    task_id: str | None = None,
+    mr_ref: str | None = None,
+) -> list[CommentView]:
+    """List comments from comment refs, or only those linked to a task/MR when given."""
+    if task_id is not None and mr_ref is not None:
+        raise ValueError("Provide task_id or mr_ref, not both")
     if task_id is not None:
         ref = task_ref(task_id)
         try:
@@ -253,6 +272,13 @@ def list_comments(repo: Repository, task_id: str | None = None) -> list[CommentV
         if task is None:
             raise KeyError(f"Task not found: {task_id}")
         return _load_task_comments(repo, task)
+    if mr_ref is not None:
+        ref = _normalize_mr_ref_for_query(mr_ref)
+        try:
+            mr = get_merge_request(repo, ref)
+        except (KeyError, ValueError) as exc:
+            raise KeyError(f"Merge request not found: {mr_ref}") from exc
+        return _comments_from_oids(repo, list(mr.comments or []))
 
     comments: list[CommentView] = []
     for ref_name in repo.references:
diff --git a/pygittools/src/pygittools/tasks_query_test.py b/pygittools/src/pygittools/tasks_query_test.py
index d308b30..e2ba761 100644
--- a/pygittools/src/pygittools/tasks_query_test.py
+++ b/pygittools/src/pygittools/tasks_query_test.py
@@ -1,8 +1,9 @@
 from pathlib import Path
 
 import pytest
-from pygit2 import Oid, Repository, init_repository
+from pygit2 import Oid, Repository, Signature, init_repository
 
+from pygittools.merge import MR_REF_PREFIX, MergeRequest, create_mr_comment
 from pygittools.tasks import (
     BOARD_REF_PREFIX,
     TASK_REF_PREFIX,
@@ -172,6 +173,27 @@ def test_get_and_list_comments_from_object_store(repo: Repository) -> None:
         list_comments(repo, "missing")
 
 
+def test_list_comments_by_mr_ref(repo: Repository) -> None:
+    tb = repo.TreeBuilder()
+    tree = tb.write()
+    sig = Signature("alice", "alice@example.com")
+    commit = repo.create_commit("HEAD", sig, sig, "init", tree, [])
+    mr_ref = f"{MR_REF_PREFIX}listcomments00001"
+    mr = MergeRequest(commit, sig, ours="refs/heads/main", title="MR", name=mr_ref)
+    mr.write(repo)
+    first = create_mr_comment(repo, mr_ref, "alpha", tagger="alice <alice@example.com>")
+    second = create_mr_comment(repo, mr_ref, "beta", tagger="bob <bob@example.com>")
+
+    comments = list_comments(repo, mr_ref=mr_ref)
+    assert [c["content"] for c in comments] == ["alpha", "beta"]
+    assert [c["oid"] for c in comments] == [str(first["oid"]), str(second["oid"])]
+
+    with pytest.raises(ValueError, match="not both"):
+        list_comments(repo, task_id="notes", mr_ref=mr_ref)
+    with pytest.raises(KeyError, match="Merge request not found"):
+        list_comments(repo, mr_ref="missing")
+
+
 def test_resolve_task_from_board_entry_follows_current_ref(repo: Repository) -> None:
     task = Task(
         _empty_tree(),
diff --git a/pygitweb/src/pygitweb/merge_requests.py b/pygitweb/src/pygitweb/merge_requests.py
index e57126e..cf8d6f1 100644
--- a/pygitweb/src/pygitweb/merge_requests.py
+++ b/pygitweb/src/pygitweb/merge_requests.py
@@ -73,11 +73,6 @@ def merge_request_tag_response(
     theirs_ref = mr.theirs or ""
     theirs_url = f"/project/{project}?a=log&h={quote(theirs_ref, safe='')}" if mr.theirs else ""
 
-    comments_rows: list[tuple[str, str]] = []
-    for c in mr.comments:
-        ch = str(c)
-        comments_rows.append((ch[:7], f"/project/{project}?a=tag&h={quote(ch, safe='')}"))
-
     current_tag_oid = str(repo.references[mr.name].resolve().target)
 
     ctx = {
@@ -86,6 +81,7 @@ def merge_request_tag_response(
         "tag_name": tag_name,
         "tag_oid": current_tag_oid,
         "tag_view_url": f"/project/{project}?a=tag&h={quote(current_tag_oid, safe='')}",
+        "mr_ref": mr.name,
         "mr_title": mr.title,
         "mr_description": mr.description or "",
         "ours_ref": ours_ref,
@@ -100,7 +96,6 @@ def merge_request_tag_response(
         "opener": str(mr.opener),
         "created_at": mr.created_at.isoformat() if mr.created_at else "",
         "updated_at": mr.updated_at.isoformat() if mr.updated_at else "",
-        "comments": comments_rows,
         "merge_action_url": f"/mr/ff?project={quote(project, safe='')}&h={quote(current_tag_oid, safe='')}",
         "notice": notice or "",
         **status_fields,
diff --git a/pygitweb/src/pygitweb/merge_requests_test.py b/pygitweb/src/pygitweb/merge_requests_test.py
index 14b9b90..fe0969a 100644
--- a/pygitweb/src/pygitweb/merge_requests_test.py
+++ b/pygitweb/src/pygitweb/merge_requests_test.py
@@ -90,6 +90,10 @@ class TestMergeRequestTagView:
         assert "Desc line" in text
         assert "Can fast-forward" in text
         assert "refs/heads/main" in text
+        assert 'data-mr-ref="refs/tags/mr/aaaabbbbccccdddd"' in text
+        assert "mr-comments-section" in text
+        assert "/static/mr-comments.js" in text
+        assert "No comment references." not in text
 
     def test_merge_ff_updates_branch(self, mr_env: dict[str, str]) -> None:
         client = mr_env["client"]
diff --git a/pygitweb/src/pygitweb/mr_comments_test.py b/pygitweb/src/pygitweb/mr_comments_test.py
new file mode 100644
index 0000000..3b01497
--- /dev/null
+++ b/pygitweb/src/pygitweb/mr_comments_test.py
@@ -0,0 +1,216 @@
+from __future__ import annotations
+
+from collections.abc import Generator
+from pathlib import Path
+from unittest.mock import patch
+
+import pygit2
+import pytest
+from fastapi import FastAPI
+from fastapi.testclient import TestClient
+from pygittools.merge import MR_REF_PREFIX, MergeRequest, get_merge_request
+from pygittools.tasks import get_comment
+
+from pygitweb.auth_config import AuthConfig, LocalUser
+from pygitweb.config import settings
+from pygitweb.conftest import client_as_user
+from pygitweb.permissions import (
+    WILDCARD_PERMISSION_KEY,
+    Permission,
+    permission_key,
+    permissions_with_defaults,
+)
+from pygitweb.tasks import comment_router
+
+_AUTH = AuthConfig(
+    auth_mode="local",
+    local_users=[
+        LocalUser(user="author", password="secret"),
+        LocalUser(user="viewer", password="secret"),
+        LocalUser(user="root", password="secret"),
+    ],
+    oauth_permissions=permissions_with_defaults({
+        WILDCARD_PERMISSION_KEY: ["root"],
+        permission_key(Permission.COMMENTS, "demo"): ["viewer", "author"],
+    }),
+)
+
+
+def _build_client() -> TestClient:
+    app = FastAPI()
+    app.include_router(comment_router, prefix="/comments")
+    return TestClient(app)
+
+
+def _commit(repo: pygit2.Repository) -> pygit2.Oid:
+    sig = pygit2.Signature("tester", "tester@example.com")
+    tb = repo.TreeBuilder()
+    tree = tb.write()
+    oid = repo.create_commit("HEAD", sig, sig, "init", tree, [])
+    return oid
+
+
+@pytest.fixture
+def mr_comment_env(tmp_path: Path) -> Generator[dict[str, str], None, None]:
+    repo_dir = tmp_path / "demo"
+    repo = pygit2.init_repository(str(repo_dir), bare=False)
+    commit = _commit(repo)
+    mr_ref = f"{MR_REF_PREFIX}mrcommentstest001"
+    mr = MergeRequest(
+        commit,
+        pygit2.Signature("author", "author@local"),
+        ours="refs/heads/main",
+        title="Discuss",
+        name=mr_ref,
+    )
+    mr.write(repo)
+    with (
+        patch.object(settings, "PROJECTROOT", str(tmp_path)),
+        patch.object(settings, "PROJECTS_LIST", str(tmp_path)),
+        patch.object(settings, "STRICT_EXPORT", False),
+        patch.object(settings, "EXPORT_OK", ""),
+        patch.object(settings, "LIST_ALL", True),
+        patch("pygitweb.auth_config.auth_config", _AUTH),
+        patch("pygitweb.auth.auth_config", _AUTH),
+    ):
+        yield {
+            "client": _build_client(),
+            "project": "demo",
+            "mr": mr_ref,
+            "repo_path": str(repo_dir),
+        }
+
+
+def test_comment_parent_requires_task_or_mr(mr_comment_env: dict[str, str]) -> None:
+    client = mr_comment_env["client"]
+    assert isinstance(client, TestClient)
+    with patch.object(settings, "AUTH", False):
+        both = client.get(
+            "/comments/list",
+            params={
+                "project": mr_comment_env["project"],
+                "board": "Tasks",
+                "task": "refs/tags/tasks/x",
+                "mr": mr_comment_env["mr"],
+            },
+        )
+        neither = client.get("/comments/list", params={"project": mr_comment_env["project"]})
+    assert both.status_code == 422
+    assert neither.status_code == 422
+
+
+def test_mr_comment_create_list_modify_delete(mr_comment_env: dict[str, str]) -> None:
+    client = mr_comment_env["client"]
+    assert isinstance(client, TestClient)
+    project = mr_comment_env["project"]
+    mr = mr_comment_env["mr"]
+    with patch.object(settings, "AUTH", False):
+        create = client.post(
+            "/comments/create",
+            params={"project": project, "mr": mr},
+            json={"content": "first note"},
+        )
+        assert create.status_code == 200
+        body = create.json()
+        oid = body["oid"]
+        assert body["comments_count"] == 1
+        assert body["mr_oid"]
+
+        listed = client.get("/comments/list", params={"project": project, "mr": mr})
+        assert listed.status_code == 200
+        assert listed.json()[0]["oid"] == oid
+        assert listed.json()[0]["content"] == "first note"
+
+        modified = client.post(
+            "/comments/modify",
+            params={"project": project, "mr": mr, "comment": oid},
+            json={"content": "edited note"},
+        )
+        assert modified.status_code == 200
+        new_oid = modified.json()["oid"]
+        assert new_oid != oid
+        assert modified.json()["content"] == "edited note"
+        assert modified.json()["mr_oid"]
+
+        deleted = client.post(
+            "/comments/delete",
+            params={"project": project, "mr": mr, "comment": new_oid},
+        )
+        assert deleted.status_code == 200
+        assert deleted.json()["message"] == "Comment deleted"
+        assert deleted.json()["mr_oid"]
+
+    repo = pygit2.Repository(mr_comment_env["repo_path"])
+    assert get_merge_request(repo, mr).comments == []
+
+
+def test_mr_comment_modify_allowed_for_author(mr_comment_env: dict[str, str]) -> None:
+    client = mr_comment_env["client"]
+    assert isinstance(client, TestClient)
+    project = mr_comment_env["project"]
+    mr = mr_comment_env["mr"]
+    repo = pygit2.Repository(mr_comment_env["repo_path"])
+    from pygittools.merge import create_mr_comment
+
+    seeded = create_mr_comment(repo, mr, "seed", tagger="author <author@local>")
+    oid = str(seeded["oid"])
+    with patch.object(settings, "AUTH", True), client_as_user(client, "author"):
+        r = client.post(
+            "/comments/modify",
+            params={"project": project, "mr": mr, "comment": oid},
+            json={"content": "by author"},
+        )
+    assert r.status_code == 200
+    assert r.json()["content"] == "by author"
+
+
+def test_mr_comment_modify_forbidden_for_non_author_with_comments_grant(
+    mr_comment_env: dict[str, str],
+) -> None:
+    client = mr_comment_env["client"]
+    assert isinstance(client, TestClient)
+    project = mr_comment_env["project"]
+    mr = mr_comment_env["mr"]
+    repo = pygit2.Repository(mr_comment_env["repo_path"])
+    from pygittools.merge import create_mr_comment
+
+    seeded = create_mr_comment(repo, mr, "seed", tagger="author <author@local>")
+    oid = str(seeded["oid"])
+    with patch.object(settings, "AUTH", True), client_as_user(client, "viewer"):
+        r = client.post(
+            "/comments/modify",
+            params={"project": project, "mr": mr, "comment": oid},
+            json={"content": "hijack"},
+        )
+    assert r.status_code == 403
+    assert get_comment(repo, pygit2.Oid(hex=oid)).content == "seed"
+
+
+def test_mr_comment_delete_allowed_for_author_and_star(mr_comment_env: dict[str, str]) -> None:
+    client = mr_comment_env["client"]
+    assert isinstance(client, TestClient)
+    project = mr_comment_env["project"]
+    mr = mr_comment_env["mr"]
+    repo = pygit2.Repository(mr_comment_env["repo_path"])
+    from pygittools.merge import create_mr_comment
+
+    author_comment = create_mr_comment(repo, mr, "mine", tagger="author <author@local>")
+    other_comment = create_mr_comment(repo, mr, "theirs", tagger="author <author@local>")
+    with patch.object(settings, "AUTH", True), client_as_user(client, "author"):
+        own = client.post(
+            "/comments/delete",
+            params={"project": project, "mr": mr, "comment": str(author_comment["oid"])},
+        )
+    assert own.status_code == 200
+    with patch.object(settings, "AUTH", True), client_as_user(client, "viewer"):
+        denied = client.post(
+            "/comments/delete",
+            params={"project": project, "mr": mr, "comment": str(other_comment["oid"])},
+        )
+    assert denied.status_code == 403
+    with patch.object(settings, "AUTH", True), client_as_user(client, "root"):
+        allowed = client.post(
+            "/comments/delete",
+            params={"project": project, "mr": mr, "comment": str(other_comment["oid"])},
+        )
+    assert allowed.status_code == 200
diff --git a/pygitweb/src/pygitweb/static/mr-comments.js b/pygitweb/src/pygitweb/static/mr-comments.js
new file mode 100644
index 0000000..e5c513f
--- /dev/null
+++ b/pygitweb/src/pygitweb/static/mr-comments.js
@@ -0,0 +1,368 @@
+import { postJson } from "./board-context.js";
+import { setMarkdownElement } from "./board-markdown.js";
+
+var mrAuth = { auth_enabled: false, username: null };
+
+function loadMrAuthStatus() {
+  return fetch('/auth/status', { credentials: 'same-origin' })
+    .then(function(res) { return res.ok ? res.json() : null; })
+    .then(function(s) {
+      if (!s) return;
+      mrAuth.auth_enabled = !!s.auth_enabled;
+      mrAuth.username = s.username || null;
+    })
+    .catch(function() {});
+}
+
+function canAddComment() {
+  return !mrAuth.auth_enabled || !!mrAuth.username;
+}
+
+function showMrError(message) {
+  var section = document.querySelector('.mr-comments-section');
+  var anchor = section && section.closest('.card-body');
+  if (!anchor) anchor = document.querySelector('.page-title') && document.querySelector('.page-title').parentNode;
+  if (!anchor) return;
+  var existing = document.querySelector('.board-task-error-hint');
+  if (existing) existing.remove();
+  var el = document.createElement('div');
+  el.className = 'alert board-task-error-hint py-2 px-3 mb-2';
+  el.setAttribute('role', 'alert');
+  el.textContent = message;
+  anchor.insertBefore(el, anchor.firstChild);
+  window.setTimeout(function() {
+    if (el.parentNode) el.remove();
+  }, 8000);
+}
+
+function commentAuthorInitials(author) {
+  var parts = (author || '').trim().split(/\s+/).filter(Boolean);
+  if (!parts.length) return '?';
+  if (parts.length === 1) return parts[0].charAt(0).toUpperCase();
+  return (parts[0].charAt(0) + parts[parts.length - 1].charAt(0)).toUpperCase();
+}
+
+function commentAvatarHtml(comment) {
+  var wrap = document.createElement('span');
+  wrap.className = 'board-card-comment-avatar';
+  if (comment.gravatar_url) {
+    var img = document.createElement('img');
+    img.src = comment.gravatar_url;
+    img.alt = '';
+    img.width = 32;
+    img.height = 32;
+    img.onerror = function() {
+      wrap.replaceChildren();
+      var fb = document.createElement('span');
+      fb.className = 'board-card-comment-avatar-fallback';
+      fb.textContent = commentAuthorInitials(comment.author);
+      wrap.appendChild(fb);
+    };
+    wrap.appendChild(img);
+  } else {
+    var fb = document.createElement('span');
+    fb.className = 'board-card-comment-avatar-fallback';
+    fb.textContent = commentAuthorInitials(comment.author);
+    wrap.appendChild(fb);
+  }
+  return wrap;
+}
+
+function commentActionButton(action, label, className) {
+  var btn = document.createElement('button');
+  btn.type = 'button';
+  btn.className = className;
+  btn.dataset.commentAction = action;
+  btn.textContent = label;
+  return btn;
+}
+
+function getMrSection() {
+  return document.querySelector('.mr-comments-section');
+}
+
+function mrContext(section) {
+  var root = section || getMrSection();
+  if (!root) return null;
+  var project = root.dataset.project || '';
+  var mr = root.dataset.mrRef || '';
+  if (!project || !mr) return null;
+  return { project: project, mr: mr, tagOid: root.dataset.tagOid || '' };
+}
+
+function maybeFollowMrTip(section, mrOid) {
+  if (!mrOid || !section) return false;
+  var current = section.dataset.tagOid || '';
+  if (!current || mrOid === current) return false;
+  var project = section.dataset.project || '';
+  if (!project) return false;
+  section.dataset.tagOid = mrOid;
+  var url = '/project/' + encodeURIComponent(project) + '?a=tag&h=' + encodeURIComponent(mrOid);
+  window.location.replace(url);
+  return true;
+}
+
+function renderCommentsList(section, comments) {
+  var list = section.querySelector('.mr-comments-list');
+  if (!list) return;
+  list.innerHTML = '';
+  if (!Array.isArray(comments) || !comments.length) {
+    var empty = document.createElement('p');
+    empty.className = 'text-muted mb-0 mr-comments-empty';
+    empty.textContent = 'No comments yet.';
+    list.appendChild(empty);
+    return;
+  }
+  comments.forEach(function(comment) {
+    var row = document.createElement('div');
+    row.className = 'board-card-comment-item';
+    if (comment.oid) row.dataset.commentOid = comment.oid;
+    row.dataset.commentContent = comment.content || '';
+    row.appendChild(commentAvatarHtml(comment));
+    var body = document.createElement('div');
+    body.className = 'board-card-comment-body';
+    var header = document.createElement('div');
+    header.className = 'board-card-comment-header';
+    var authorEl = document.createElement('div');
+    authorEl.className = 'board-card-comment-author';
+    authorEl.textContent = comment.author || 'Unknown';
+    header.appendChild(authorEl);
+    if (comment.can_edit || comment.can_delete) {
+      var actions = document.createElement('div');
+      actions.className = 'board-card-comment-actions';
+      if (comment.can_edit) {
+        actions.appendChild(commentActionButton(
+          'edit',
+          'Edit',
+          'btn btn-sm btn-link board-card-comment-edit-btn'
+        ));
+      }
+      if (comment.can_delete) {
+        actions.appendChild(commentActionButton(
+          'delete',
+          'Delete',
+          'btn btn-sm btn-link text-danger board-card-comment-delete-btn'
+        ));
+      }
+      header.appendChild(actions);
+    }
+    var contentEl = document.createElement('div');
+    contentEl.className = 'board-card-comment-content';
+    setMarkdownElement(contentEl, comment.content || '');
+    body.appendChild(header);
+    body.appendChild(contentEl);
+    row.appendChild(body);
+    list.appendChild(row);
+  });
+}
+
+function syncCommentFormVisibility(section) {
+  var form = section.querySelector('.mr-comment-form');
+  var hint = section.querySelector('.mr-comment-signin-hint');
+  if (!form || !hint) return;
+  if (canAddComment()) {
+    form.classList.remove('d-none');
+    hint.classList.add('d-none');
+  } else {
+    form.classList.add('d-none');
+    hint.classList.remove('d-none');
+  }
+}
+
+function exitCommentEditMode(row) {
+  var editor = row.querySelector('.board-card-comment-edit');
+  if (editor) editor.remove();
+  var contentEl = row.querySelector('.board-card-comment-content');
+  if (contentEl) contentEl.classList.remove('d-none');
+  var actions = row.querySelector('.board-card-comment-actions');
+  if (actions) actions.classList.remove('d-none');
+}
+
+function enterCommentEditMode(row) {
+  if (row.querySelector('.board-card-comment-edit')) return;
+  var body = row.querySelector('.board-card-comment-body');
+  var contentEl = row.querySelector('.board-card-comment-content');
+  if (!body || !contentEl) return;
+  var actions = row.querySelector('.board-card-comment-actions');
+  if (actions) actions.classList.add('d-none');
+  contentEl.classList.add('d-none');
+  var editor = document.createElement('div');
+  editor.className = 'board-card-comment-edit mt-1';
+  var input = document.createElement('textarea');
+  input.className = 'form-control form-control-sm board-card-comment-edit-input';
+  input.rows = 3;
+  input.value = row.dataset.commentContent || '';
+  input.setAttribute('aria-label', 'Edit comment');
+  var controls = document.createElement('div');
+  controls.className = 'd-flex gap-2 mt-1';
+  controls.appendChild(commentActionButton(
+    'save',
+    'Save',
+    'btn btn-sm btn-primary board-card-comment-save-btn'
+  ));
+  controls.appendChild(commentActionButton(
+    'cancel',
+    'Cancel',
+    'btn btn-sm btn-outline-secondary board-card-comment-cancel-btn'
+  ));
+  editor.appendChild(input);
+  editor.appendChild(controls);
+  body.appendChild(editor);
+  input.focus();
+}
+
+function commentParams(section, oid) {
+  var ctx = mrContext(section);
+  if (!ctx || !oid) return null;
+  return { project: ctx.project, mr: ctx.mr, comment: oid };
+}
+
+export function loadMrComments(section) {
+  var root = section || getMrSection();
+  var ctx = mrContext(root);
+  if (!root || !ctx) return Promise.resolve();
+  setupMrCommentListActions(root);
+  var listUrl = '/comments/list?' + new URLSearchParams({
+    project: ctx.project,
+    mr: ctx.mr
+  }).toString();
+  return fetch(listUrl, { credentials: 'same-origin' })
+    .then(function(res) { return res.ok ? res.json() : []; })
+    .then(function(comments) {
+      if (!Array.isArray(comments)) comments = [];
+      renderCommentsList(root, comments);
+      return comments;
+    })
+    .catch(function() { return []; });
+}
+
+function saveCommentEdit(section, row) {
+  var params = commentParams(section, row.dataset.commentOid);
+  var input = row.querySelector('.board-card-comment-edit-input');
+  if (!params || !input) return;
+  var content = input.value.trim();
+  if (!content) {
+    showMrError('Comment cannot be empty.');
+    return;
+  }
+  postJson('/comments/modify', params, { content: content })
+    .then(function(res) {
+      if (!res.ok) {
+        var msg = (res.status === 401 || res.status === 403)
+          ? 'Not authorized to edit this comment.'
+          : 'Could not update comment.';
+        showMrError(msg);
+        return null;
+      }
+      return res.json().then(function(body) {
+        if (maybeFollowMrTip(section, body && body.mr_oid)) return null;
+        return loadMrComments(section);
+      });
+    })
+    .catch(function() {
+      showMrError('Could not update comment.');
+    });
+}
+
+function deleteComment(section, row) {
+  var params = commentParams(section, row.dataset.commentOid);
+  if (!params) return;
+  if (!window.confirm('Delete this comment? This cannot be undone.')) return;
+  postJson('/comments/delete', params)
+    .then(function(res) {
+      if (!res.ok) {
+        var msg = (res.status === 401 || res.status === 403)
+          ? 'Not authorized to delete this comment.'
+          : 'Could not delete comment.';
+        showMrError(msg);
+        return null;
+      }
+      return res.json().then(function(body) {
+        if (maybeFollowMrTip(section, body && body.mr_oid)) return null;
+        return loadMrComments(section);
+      });
+    })
+    .catch(function() {
+      showMrError('Could not delete comment.');
+    });
+}
+
+function setupMrCommentListActions(section) {
+  var list = section.querySelector('.mr-comments-list');
+  if (!list || list.dataset.bound === '1') return;
+  list.dataset.bound = '1';
+  list.addEventListener('click', function(e) {
+    var btn = e.target.closest('[data-comment-action]');
+    if (!btn || !list.contains(btn)) return;
+    var row = btn.closest('.board-card-comment-item');
+    if (!row) return;
+    var action = btn.dataset.commentAction;
+    if (action === 'edit') {
+      enterCommentEditMode(row);
+      return;
+    }
+    if (action === 'cancel') {
+      exitCommentEditMode(row);
+      return;
+    }
+    if (action === 'save') {
+      saveCommentEdit(section, row);
+      return;
+    }
+    if (action === 'delete') {
+      deleteComment(section, row);
+    }
+  });
+}
+
+export function setupMrCommentForm(section) {
+  var root = section || getMrSection();
+  if (!root) return;
+  setupMrCommentListActions(root);
+  syncCommentFormVisibility(root);
+  var form = root.querySelector('.mr-comment-form');
+  if (!form || form.dataset.bound === '1') return;
+  form.dataset.bound = '1';
+  form.addEventListener('submit', function(e) {
+    e.preventDefault();
+    if (!canAddComment()) return;
+    var ctx = mrContext(root);
+    if (!ctx) return;
+    var input = form.querySelector('.mr-comment-input');
+    var content = (input && input.value) ? input.value.trim() : '';
+    if (!content) return;
+    postJson(
+      '/comments/create',
+      { project: ctx.project, mr: ctx.mr },
+      { content: content }
+    )
+      .then(function(res) {
+        if (!res.ok) {
+          var msg = (res.status === 401 || res.status === 403)
+            ? 'Not authorized to add comments (sign in again if needed).'
+            : 'Could not post comment.';
+          showMrError(msg);
+          return null;
+        }
+        return res.json().then(function(body) {
+          if (input) input.value = '';
+          if (maybeFollowMrTip(root, body && body.mr_oid)) return null;
+          return loadMrComments(root);
+        });
+      })
+      .catch(function() {
+        showMrError('Could not post comment.');
+      });
+  });
+}
+
+export function initMrComments() {
+  var section = getMrSection();
+  if (!section) return Promise.resolve();
+  return loadMrAuthStatus().then(function() {
+    setupMrCommentForm(section);
+    return loadMrComments(section);
+  });
+}
+
+initMrComments();
diff --git a/pygitweb/src/pygitweb/static_tests/test_mr-comments.py b/pygitweb/src/pygitweb/static_tests/test_mr-comments.py
new file mode 100644
index 0000000..7bef6e4
--- /dev/null
+++ b/pygitweb/src/pygitweb/static_tests/test_mr-comments.py
@@ -0,0 +1,145 @@
+from __future__ import annotations
+
+from pygitweb.static_tests.js_runtime import JsPage
+from pygitweb.static_tests.pages import posted_json, request_query, requested
+
+
+def _mr_shell(
+    *,
+    project: str = "demo",
+    mr_ref: str = "refs/tags/mr/aaaabbbbccccdddd",
+    tag_oid: str = "1" * 40,
+) -> str:
+    return (
+        f'<div class="card-body">'
+        f'<div class="mr-comments-section" data-project="{project}" '
+        f'data-mr-ref="{mr_ref}" data-tag-oid="{tag_oid}">'
+        '<div class="mr-comments-list"></div>'
+        '<form class="mr-comment-form d-none">'
+        '<textarea class="mr-comment-input"></textarea>'
+        '<button type="submit">Post comment</button></form>'
+        '<p class="mr-comment-signin-hint d-none">Sign in</p>'
+        "</div></div>"
+    )
+
+
+def _load(js: JsPage) -> None:
+    js.set_html(_mr_shell())
+    js.route("comments/list", body=[])
+    js.route("/auth/status", body={"auth_enabled": False})
+    js.load("mr-comments.js")
+    js.tick()
+
+
+def test_mr_comments_render_and_actions_matrix(js: JsPage) -> None:
+    js.route(
+        "comments/list",
+        body=[
+            {"oid": "a1", "author": "ada", "content": "**hi**", "can_edit": True, "can_delete": True},
+            {"oid": "b2", "author": "bob", "content": "theirs", "can_edit": False, "can_delete": True},
+            {"oid": "c3", "author": "cara", "content": "locked", "can_edit": False, "can_delete": False},
+        ],
+    )
+    js.route("/auth/status", body={"auth_enabled": False})
+    js.set_html(_mr_shell())
+    js.load("mr-comments.js")
+    js.tick()
+    assert js.count(".board-card-comment-item") == 3
+    assert js.count(".board-card-comment-content strong") == 1
+    items = js.value(
+        "Array.from(document.querySelectorAll('.board-card-comment-item')).map(function(row) {"
+        "  return {"
+        "    oid: row.dataset.commentOid,"
+        "    edit: !!row.querySelector('.board-card-comment-edit-btn'),"
+        "    del: !!row.querySelector('.board-card-comment-delete-btn')"
+        "  };"
+        "})"
+    )
+    assert items == [
+        {"oid": "a1", "edit": True, "del": True},
+        {"oid": "b2", "edit": False, "del": True},
+        {"oid": "c3", "edit": False, "del": False},
+    ]
+    assert "d-none" not in js.classes(".mr-comment-form")
+
+
+def test_mr_comment_form_hides_until_signed_in(js: JsPage) -> None:
+    js.route("/auth/status", body={"auth_enabled": True})
+    js.route("comments/list", body=[])
+    js.set_html(_mr_shell())
+    js.load("mr-comments.js")
+    js.tick()
+    assert "d-none" in js.classes(".mr-comment-form")
+    assert "d-none" not in js.classes(".mr-comment-signin-hint")
+
+
+def test_submitting_mr_comment_posts_and_reloads(js: JsPage) -> None:
+    js.route("/auth/status", body={"auth_enabled": False})
+    js.route("comments/create", status=200, body={"oid": "new", "mr_oid": "1" * 40})
+    js.route("comments/list", body=[])
+    js.set_html(_mr_shell())
+    js.load("mr-comments.js")
+    js.tick()
+    js.route(
+        "comments/list",
+        body=[{"oid": "new", "author": "ada", "content": "hello", "can_edit": True, "can_delete": True}],
+    )
+    js.set_prop(".mr-comment-input", "value", "  hello  ")
+    js.dispatch(".mr-comment-form", "submit")
+    q = request_query(js, "comments/create")
+    assert q["mr"] == "refs/tags/mr/aaaabbbbccccdddd"
+    assert "task" not in q
+    assert posted_json(js, "comments/create") == {"content": "hello"}
+    assert js.text(".board-card-comment-content") == "hello"
+
+
+def test_mr_comment_create_errors_are_shown(js: JsPage) -> None:
+    _load(js)
+    js.set_prop(".mr-comment-input", "value", "hello")
+    for status, snippet in ((401, "Not authorized"), (500, "Could not post comment")):
+        js.route("comments/create", status=status, text="no")
+        js.dispatch(".mr-comment-form", "submit")
+        assert snippet in js.text(".board-task-error-hint")
+        js.tick()
+
+
+def test_editing_mr_comment_posts_modify(js: JsPage) -> None:
+    js.route("/auth/status", body={"auth_enabled": False})
+    js.route(
+        "comments/list",
+        body=[{"oid": "abc", "author": "ada", "content": "before", "can_edit": True, "can_delete": False}],
+    )
+    js.route("comments/modify", status=200, body={"oid": "def", "content": "after", "mr_oid": "1" * 40})
+    js.set_html(_mr_shell())
+    js.load("mr-comments.js")
+    js.tick()
+    js.click(".board-card-comment-edit-btn")
+    js.set_prop(".board-card-comment-edit-input", "value", "after")
+    js.route(
+        "comments/list",
+        body=[{"oid": "def", "author": "ada", "content": "after", "can_edit": True, "can_delete": False}],
+    )
+    js.click(".board-card-comment-save-btn")
+    assert request_query(js, "comments/modify")["comment"] == "abc"
+    assert posted_json(js, "comments/modify") == {"content": "after"}
+    assert js.text(".board-card-comment-content") == "after"
+
+
+def test_deleting_mr_comment_confirms_and_posts(js: JsPage) -> None:
+    js.route("/auth/status", body={"auth_enabled": False})
+    js.route(
+        "comments/list",
+        body=[{"oid": "gone", "author": "ada", "content": "bye", "can_edit": False, "can_delete": True}],
+    )
+    js.route("comments/delete", status=200, body={"message": "Comment deleted", "mr_oid": "1" * 40})
+    js.set_html(_mr_shell())
+    js.load("mr-comments.js")
+    js.tick()
+    js.run("__confirmYes = false; __confirms = [];")
+    js.click(".board-card-comment-delete-btn")
+    assert requested(js, "comments/delete") is False
+    js.run("__confirmYes = true;")
+    js.route("comments/list", body=[])
+    js.click(".board-card-comment-delete-btn")
+    assert request_query(js, "comments/delete")["comment"] == "gone"
+    assert "No comments yet" in js.text(".mr-comments-empty")
diff --git a/pygitweb/src/pygitweb/tasks.py b/pygitweb/src/pygitweb/tasks.py
index e7b8818..c99eb1d 100644
--- a/pygitweb/src/pygitweb/tasks.py
+++ b/pygitweb/src/pygitweb/tasks.py
@@ -16,6 +16,13 @@ from fastapi import APIRouter, Depends, HTTPException, Query
 from fastapi.responses import HTMLResponse, JSONResponse
 from pydantic import BaseModel, BeforeValidator, Field
 from pygit2 import Oid
+from pygittools.merge import (
+    MR_REF_PREFIX,
+    create_mr_comment,
+    delete_mr_comment,
+    get_merge_request,
+    modify_mr_comment,
+)
 from pygittools.tasks import (
     ARCHIVE_BOARD_NAME,
     BOARD_REF_PREFIX,
@@ -730,21 +737,61 @@ def _comment_sort_key(entry: dict[str, Any]) -> str:
     return entry.get("created_at") or ""
 
 
-@comment_router.get("/list")
-def comment_list(
-    project: ValidatedReadableProject,
-    board: str = Query(..., description="Board name"),
-    task: str = Query(..., description="Task ref (e.g. refs/tags/tasks/task_123)"),
-    token: Annotated[str | None, Depends(access_token_from_request)] = None,
-) -> JSONResponse:
-    """List all comments for a task."""
-    repo = pygit2.Repository(os.path.join(settings.PROJECTROOT, project))
-    task_ref = _full_task_ref(task)
-    t = _find_task(repo, task_ref)
+def _normalize_mr_ref(mr: str) -> str:
+    if mr.startswith("refs/"):
+        return mr
+    if mr.startswith("mr/"):
+        return f"refs/tags/{mr}"
+    return f"{MR_REF_PREFIX}{mr}"
+
+
+def _comment_parent(
+    board: str | None,
+    task: str | None,
+    mr: str | None,
+) -> tuple[str, str, str | None]:
+    """Return ``(kind, parent_ref, board)`` where kind is ``task`` or ``mr``."""
+    has_task = bool(task and task.strip())
+    has_mr = bool(mr and mr.strip())
+    if has_task == has_mr:
+        raise HTTPException(
+            status_code=422,
+            detail="Provide either task and board, or mr",
+        )
+    if has_mr:
+        assert mr is not None
+        return ("mr", _normalize_mr_ref(mr), None)
+    if not board or not board.strip():
+        raise HTTPException(status_code=422, detail="board is required when task is set")
+    assert task is not None
+    return ("task", _full_task_ref(task), board)
+
+
+def _comment_oids_for_parent(
+    repo: pygit2.Repository,
+    kind: str,
+    parent_ref: str,
+) -> list[str | pygit2.Oid]:
+    if kind == "mr":
+        try:
+            mr_obj = get_merge_request(repo, parent_ref)
+        except (KeyError, ValueError) as exc:
+            raise HTTPException(status_code=404, detail="Merge request not found") from exc
+        return list(mr_obj.comments or [])
+    t = _find_task(repo, parent_ref)
     if not t:
         raise HTTPException(status_code=404, detail="Task not found")
-    comment_oids = getattr(t, "comments", []) or []
-    comments = []
+    return list(getattr(t, "comments", []) or [])
+
+
+def _comments_json_for_oids(
+    repo: pygit2.Repository,
+    comment_oids: list[str | pygit2.Oid],
+    *,
+    project: str,
+    token: str | None,
+) -> list[dict[str, Any]]:
+    comments: list[dict[str, Any]] = []
     for oid_hex in comment_oids:
         try:
             oid = pygit2.Oid(hex=oid_hex) if isinstance(oid_hex, str) else oid_hex
@@ -753,7 +800,22 @@ def comment_list(
         except (ValueError, KeyError, TypeError):
             continue
     comments.sort(key=_comment_sort_key)
-    return JSONResponse(content=comments)
+    return comments
+
+
+@comment_router.get("/list")
+def comment_list(
+    project: ValidatedReadableProject,
+    board: str | None = Query(None, description="Board name (required with task)"),
+    task: str | None = Query(None, description="Task ref (e.g. refs/tags/tasks/task_123)"),
+    mr: str | None = Query(None, description="Merge request ref (e.g. refs/tags/mr/...)"),
+    token: Annotated[str | None, Depends(access_token_from_request)] = None,
+) -> JSONResponse:
+    """List comments for a task or merge request."""
+    kind, parent_ref, _board = _comment_parent(board, task, mr)
+    repo = pygit2.Repository(os.path.join(settings.PROJECTROOT, project))
+    comment_oids = _comment_oids_for_parent(repo, kind, parent_ref)
+    return JSONResponse(content=_comments_json_for_oids(repo, comment_oids, project=project, token=token))
 
 
 @comment_router.post(
@@ -763,27 +825,46 @@ def comment_list(
 def comment_create(
     project: ValidatedReadableProject,
     comment: CommentCreateBody,
-    board: str = Query(..., description="Board name"),
-    task: str = Query(..., description="Task ref"),
+    board: str | None = Query(None, description="Board name (required with task)"),
+    task: str | None = Query(None, description="Task ref"),
+    mr: str | None = Query(None, description="Merge request ref"),
     token: Annotated[str | None, Depends(access_token_from_request)] = None,
 ) -> JSONResponse:
-    """Create a new comment on a task."""
+    """Create a new comment on a task or merge request."""
+    kind, parent_ref, board_name = _comment_parent(board, task, mr)
     repo = pygit2.Repository(os.path.join(settings.PROJECTROOT, project))
-    task_ref = _full_task_ref(task)
-    if _find_task(repo, task_ref) is None:
-        raise HTTPException(status_code=404, detail="Task not found")
     tagger = _tagger_from_principal(principal_from_session(token))
     try:
+        if kind == "mr":
+            result_mr = create_mr_comment(
+                repo,
+                parent_ref,
+                comment.content or "",
+                tagger=tagger,
+            )
+            mr_after = get_merge_request(repo, parent_ref)
+            comments_count = len(mr_after.comments or [])
+            return JSONResponse(
+                content={
+                    "oid": str(result_mr["oid"]),
+                    "message": "Comment created",
+                    "comments_count": comments_count,
+                    "mr_oid": str(result_mr["mr_oid"]),
+                }
+            )
+        if _find_task(repo, parent_ref) is None:
+            raise HTTPException(status_code=404, detail="Task not found")
         result = create_comment(
             repo,
-            task_ref,
+            parent_ref,
             comment.content or "",
             tagger=tagger,
-            board=board,
+            board=board_name,
         )
     except KeyError as exc:
-        raise HTTPException(status_code=404, detail="Task not found") from exc
-    task_after = get_task(repo, task_ref)
+        detail = "Merge request not found" if kind == "mr" else "Task not found"
+        raise HTTPException(status_code=404, detail=detail) from exc
+    task_after = get_task(repo, parent_ref)
     comments_count = len(getattr(task_after, "comments", []) or []) if task_after else 1
     return JSONResponse(
         content={
@@ -798,23 +879,39 @@ def comment_create(
 def comment_modify(
     project: ValidatedReadableProject,
     fields: CommentModifyBody,
-    board: str = Query(..., description="Board name"),
-    task: str = Query(..., description="Task ref"),
     comment: str = Query(..., description="Comment OID hex"),
+    board: str | None = Query(None, description="Board name (required with task)"),
+    task: str | None = Query(None, description="Task ref"),
+    mr: str | None = Query(None, description="Merge request ref"),
     token: Annotated[str | None, Depends(access_token_from_request)] = None,
 ) -> JSONResponse:
     """Modify a comment's content. Author only."""
+    kind, parent_ref, board_name = _comment_parent(board, task, mr)
     repo = pygit2.Repository(os.path.join(settings.PROJECTROOT, project))
     oid, c = _load_comment(repo, comment)
     _ensure_comment_edit_allowed(project, token, c.tagger)
     content = c.content if fields.content is None else fields.content
     try:
+        if kind == "mr":
+            result_mr = modify_mr_comment(repo, oid, content, mr_ref=parent_ref)
+            return JSONResponse(
+                content={
+                    **_comment_to_json(
+                        result_mr["comment"],
+                        oid=str(result_mr["oid"]),
+                        project=project,
+                        token=token,
+                    ),
+                    "message": "Comment updated",
+                    "mr_oid": str(result_mr["mr_oid"]),
+                }
+            )
         result = modify_comment(
             repo,
             oid,
             content,
-            task_ref=_full_task_ref(task),
-            board=board,
+            task_ref=parent_ref,
+            board=board_name,
         )
     except KeyError as exc:
         raise HTTPException(status_code=404, detail="Comment not found") from exc
@@ -834,17 +931,22 @@ def comment_modify(
 @comment_router.post("/delete")
 def comment_delete(
     project: ValidatedReadableProject,
-    board: str = Query(..., description="Board name"),
-    task: str = Query(..., description="Task ref"),
     comment: str = Query(..., description="Comment OID hex"),
+    board: str | None = Query(None, description="Board name (required with task)"),
+    task: str | None = Query(None, description="Task ref"),
+    mr: str | None = Query(None, description="Merge request ref"),
     token: Annotated[str | None, Depends(access_token_from_request)] = None,
 ) -> JSONResponse:
     """Delete a comment. Author or ``*`` (superuser) grant required."""
+    kind, parent_ref, board_name = _comment_parent(board, task, mr)
     repo = pygit2.Repository(os.path.join(settings.PROJECTROOT, project))
     oid, c = _load_comment(repo, comment)
     _ensure_comment_delete_allowed(project, token, c.tagger)
     try:
-        delete_comment(repo, oid, task_ref=_full_task_ref(task), board=board)
+        if kind == "mr":
+            mr_oid = delete_mr_comment(repo, oid, mr_ref=parent_ref)
+            return JSONResponse(content={"message": "Comment deleted", "mr_oid": str(mr_oid)})
+        delete_comment(repo, oid, task_ref=parent_ref, board=board_name)
     except KeyError as exc:
         raise HTTPException(status_code=404, detail="Comment not found") from exc
     return JSONResponse(content={"message": "Comment deleted"})
diff --git a/pygitweb/src/pygitweb/templates/merge_request_tag.html b/pygitweb/src/pygitweb/templates/merge_request_tag.html
index 4a70db3..f7bbba8 100644
--- a/pygitweb/src/pygitweb/templates/merge_request_tag.html
+++ b/pygitweb/src/pygitweb/templates/merge_request_tag.html
@@ -1,6 +1,6 @@
 {% extends "base.html" %}
 {% block content %}
-{# Merge request view for annotated MR tags. Expects: project, project_url, tag_name, tag_oid, tag_view_url, mr_title, mr_description, ours_ref, ours_url, theirs_ref, theirs_url, head_short, head_url, head_full, tagger, tagger_date, opener, created_at, updated_at, comments [ (short, url) ], merge_action_url, status_code, status_label, status_detail, show_merge_button #}
+{# Merge request view for annotated MR tags. Expects: project, project_url, tag_name, tag_oid, tag_view_url, mr_ref, mr_title, mr_description, ours_ref, ours_url, theirs_ref, theirs_url, head_short, head_url, head_full, tagger, tagger_date, opener, created_at, updated_at, merge_action_url, status_code, status_label, status_detail, show_merge_button #}
 
 <h1 class="page-title mb-3">Merge request</h1>
 
@@ -81,17 +81,31 @@
         <h3 class="card-title">Comments</h3>
       </div>
       <div class="card-body">
-        {% if comments %}
-        <ul class="list-unstyled mb-0">
-          {% for short_id, url in comments %}
-          <li class="mb-1"><a href="{{ url }}">{{ short_id }}</a></li>
-          {% endfor %}
-        </ul>
-        {% else %}
-        <p class="text-muted mb-0">No comment references.</p>
-        {% endif %}
+        <div
+          class="mr-comments-section"
+          data-project="{{ project }}"
+          data-mr-ref="{{ mr_ref }}"
+          data-tag-oid="{{ tag_oid }}"
+        >
+          <div class="mr-comments-list"></div>
+          <form class="mr-comment-form d-none mt-3" action="#" method="post">
+            <textarea
+              class="form-control form-control-sm mr-comment-input"
+              rows="3"
+              placeholder="Add a comment…"
+              aria-label="Comment"
+            ></textarea>
+            <button type="submit" class="btn btn-sm btn-primary mt-2">Post comment</button>
+          </form>
+          <p class="mr-comment-signin-hint text-muted small mt-2 mb-0 d-none">Sign in to add a comment.</p>
+        </div>
       </div>
     </div>
   </div>
 </div>
 {% endblock %}
+
+{% block scripts %}
+<script defer src="/static/vendor/showdown-2.1.0.min.js"></script>
+<script type="module" src="/static/mr-comments.js"></script>
+{% endblock %}
