Prompt history is the stored record of user prompts, assistant replies, and often related task state in an AI tool. In coding assistants, it may include pasted code, file paths, architecture notes, error messages, and follow-up instructions. Because it captures working context, prompt history can become as sensitive as source repositories or API keys.
In cyber security, prompt history matters because attackers can steal it from local caches, databases, sync folders, or application logs. An infostealer that does not understand the AI system can still profit by searching for these files and extracting project details, secrets, or credentials mentioned in conversation. Defenders should treat prompt history as protected data: review where it is stored, limit retention, encrypt local state, and apply secret scanning and token rotation when sensitive material may have been exposed.


