# File Indexing, forgets the codes it wrote itself

**URL:** <https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711>\
**Category:** Help\
**Created:** [February 13, 2025, 3:07pm UTC](https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711 "2025-02-13T15:07:06Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![suloman20](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/suloman20/32/26507_2.png) [@suloman20](https://forum.cursor.com/u/suloman20)\
**Post date:** [February 13, 2025, 3:07pm UTC](https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711/1 "2025-02-13T15:07:06Z")

</div>

Hello guys, I am facing a bug that I can’t solve.

I am a new cursor user.

I’ve been using Cursor Pro for the past three days, and I’ve encountered a frustrating issue that’s making it hard to continue my work.

Everything was fine on the first day, I started a new project, generated necessary files and code, and made progress. However, on the following days, Cursor started forgetting the code it had previously written.

For example, I have an `index.html` file. When I prompt Cursor to update this file, instead of modifying `index.html`, it randomly creates a new file like `ndex.html` and tries to continue working in that file. At first, I didn’t notice this and kept pressing “Apply All,” but when my code stopped working, I realized what was happening.

Now, the situation has become unmanageable. Even after repeatedly explaining the correct file names and paths to Cursor, it sometimes recognizes them and sometimes doesn’t. I also tried resyncing the index via Codebase Indexing \> Resync Index, but the issue persists.

- Request ID: f5f68c08-3b44-471e-bd20-e556cd90b430

 ![cursor-bug](https://us1.discourse-cdn.com/cursor1/original/3X/a/2/a2c77b533532cff411372d5bba93b09fd0cd23e5.png)

---

<div class="post-metadata">

**Author:** ![deanrie](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/deanrie/32/1263_2.png) [@deanrie](https://forum.cursor.com/u/deanrie)\
**Post date:** [February 14, 2025, 4:26am UTC](https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711/2 "2025-02-14T04:26:43Z")

</div>

Hey, try restarting Cursor, and try creating a new session in the Composer from time to time. Ideally, one session per task, then everything should work fine.

---

<div class="post-metadata">

**Author:** ![suloman20](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/suloman20/32/26507_2.png) [@suloman20](https://forum.cursor.com/u/suloman20)\
**Post date:** [February 14, 2025, 11:32am UTC](https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711/3 "2025-02-14T11:32:36Z")

</div>

Hey again, first of all, thanks for your answer. I think this isn’t about restarting or creating new session, problem is different. I tried logout-login, close-open app, they didn’t work for me. But i can see bug like this:

 ![cursor-bug-3](https://us1.discourse-cdn.com/cursor1/original/3X/f/a/fa9b4268c7d7bed619f19a469f021bd23fa2cde5.png)

---

<div class="post-metadata">

**Author:** ![suloman20](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/suloman20/32/26507_2.png) [@suloman20](https://forum.cursor.com/u/suloman20)\
**Post date:** [February 14, 2025, 1:02pm UTC](https://forum.cursor.com/t/file-indexing-forgets-the-codes-it-wrote-itself/50711/4 "2025-02-14T13:02:51Z")

</div>

I solve the problem!

When I said “Make the changes without disrupting the existing functions”, it started producing new files and indexing them. My problem seems to be solved for now.
