# Cursor agent cannot write to .cursor/rules (even to \*.mdc files)

**URL:** <https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664>\
**Category:** Bug Reports\
**Created:** [March 9, 2025, 7:46pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664 "2025-03-09T19:46:07Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![IAkumaI](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/iakumai/32/34664_2.png) [@IAkumaI](https://forum.cursor.com/u/IAkumaI)\
**Post date:** [March 9, 2025, 7:46pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/1 "2025-03-09T19:46:07Z")

</div>

## Problem

I’ve tried to make Cursor to write it’s own rules. In theory it should’ve worked like:

- You solve a task in agent mode
- Ask him to update related rules to keep it updated

It just does not work. Cursor seems like does not know what “rules” is. Ok, fine, understandable. Next try.

I just write prompt like “Update @global.mdc according to what we just did”. Where global.mdc is .cursor/rules/global.mdc

Cursor sees the file, can read it and even tries to apply to the file, but in fact it silently fails. In the chat it looks like an usual file apply, but it hadn’t been applied to the actual file.

Even if I click “Apply” it doesn’t work. No errors, nothing, like it worked, but it didn’t.

Ok, i can copy the new content to the file, but would it be much better it Cursor could apply to it’s rules. Even more, seems like it cannot apply to \*.mdc at all.

## Example

I created an empty project with only global.mdc file (in the root, not in .cursor folder). And ask the agent to add info. It did, but it didn’t.

 ![Screenshot 2025-03-09 at 22.43.22](https://us1.discourse-cdn.com/cursor1/original/3X/e/d/ededd62d899f50f5ceb3941a9399665686994dd3.jpeg)

As you can see, there is no “new line” in the file. I had clicked the “apply” too.

Checking in the terminal:

 ![Screenshot 2025-03-09 at 22.43.37](https://us1.discourse-cdn.com/cursor1/original/3X/f/a/fac4b94990ba4cdb77acc2d7a957d0fb54bc8583.png)

## Sys info:

Version: 0.46.11  
VSCode Version: 1.96.2  
Commit: ae378be9dc2f5f1a6a1a220c6e25f9f03c8d4e10  
Date: 2025-03-07T06:43:50.208Z  
Electron: 32.2.6  
Chromium: 128.0.6613.186  
Node.js: 20.18.1  
V8: 12.8.374.38-electron.0  
OS: Darwin arm64 24.3.0

---

<div class="post-metadata">

**Author:** ![Biggs](https://avatars.discourse-cdn.com/v4/letter/b/e274bd/32.png) [@Biggs](https://forum.cursor.com/u/Biggs)\
**Post date:** [March 28, 2025, 12:54pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/2 "2025-03-28T12:54:23Z")

</div>

Fixed here: [Cursor agent cannot write to .cursor/rules files - #5 by jazzmind](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-files/61732/5)

---

<div class="post-metadata">

**Author:** ![lisong233](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/lisong233/32/33433_2.png) [@lisong233](https://forum.cursor.com/u/lisong233)\
**Post date:** [March 28, 2025, 12:59pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/3 "2025-03-28T12:59:13Z")

</div>

But this seems to disable the automatic ‘@file’ function in mdc rules…

---

<div class="post-metadata">

**Author:** ![condor](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/condor/32/73148_2.png) [@condor](https://forum.cursor.com/u/condor)\
**Post date:** [March 28, 2025, 12:59pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/4 "2025-03-28T12:59:42Z")

</div>

This has no effect on the USAGE of rule files

---

<div class="post-metadata">

**Author:** ![Biggs](https://avatars.discourse-cdn.com/v4/letter/b/e274bd/32.png) [@Biggs](https://forum.cursor.com/u/Biggs)\
**Post date:** [April 20, 2025, 3:10pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/5 "2025-04-20T15:10:36Z")

</div>

Since update 0.49.x, this is no longer an issue.

---

<div class="post-metadata">

**Author:** ![IAkumaI](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/iakumai/32/34664_2.png) [@IAkumaI](https://forum.cursor.com/u/IAkumaI)\
**Post date:** [April 22, 2025, 2:28pm UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/6 "2025-04-22T14:28:15Z")

</div>

Well, now we have a bug that I cannot apply changes partially. The buttons just do nothing. I can apply the whole file, but clicking “Apply” on code lines does nothing.

---

<div class="post-metadata">

**Author:** ![ma7dev](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/ma7dev/32/22547_2.png) [@ma7dev](https://forum.cursor.com/u/ma7dev)\
**Post date:** [May 7, 2025, 5:09am UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/7 "2025-05-07T05:09:26Z")

</div>

The issue hasn’t been resolved yet. I am using the latest update, and I am having the same problem. I cannot accept partial changes within the `.mdc` files in rules (`.cursor/rules`).

---

<div class="post-metadata">

**Author:** ![system](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/system/32/99069_2.png) [@system](https://forum.cursor.com/u/system)\
**Post date:** [June 6, 2025, 5:10am UTC](https://forum.cursor.com/t/cursor-agent-cannot-write-to-cursor-rules-even-to-mdc-files/61664/8 "2025-06-06T05:10:02Z")

</div>

Closed on June 6, 2025, 5:10am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
