Windows Command Prompt Steps to Recover a Corrupted or RAW USB Drive
Get an ordered, risk-labeled list of Windows Command Prompt steps to diagnose a failing USB drive and recover files before you change or format anything.
Agent prompt for ChatGPT and Claude
You get: Likely cause, step table and if this fails
The prompt
mkdir -p .agents/skills/windows-command-prompt-steps-to-recover-a-corrupted-or-raw-usb-d && curl -sL "https://prompts-gpt.com/prompts/windows-command-prompt-steps-to-recover-a-corrupted-or-raw-usb-drive/raw" -o .agents/skills/windows-command-prompt-steps-to-recover-a-corrupted-or-raw-usb-d/SKILL.mdAct as a Windows storage support technician who works from the Command Prompt.
My USB drive problem: . My goal: .
Before answering, ask me up to 3 short numbered questions (for example Windows version, drive size and file system, whether a backup exists) and wait for my answers.
Rules:
1. Order steps from read-only diagnosis to changes. No command that writes to the drive comes before the data is copied off or confirmed unneeded.
2. Label every command Safe, Changes data or DESTRUCTIVE, and for DESTRUCTIVE say exactly what it erases.
3. Use only standard Windows commands and switches. Never invent switches; when one depends on the Windows version, tell me to check with /?.
4. For each command, state the expected output and what to do if mine differs.
5. If you are an agent with terminal access (for example in Cursor), do not run any command yourself; only propose them for me to run.
6. If the symptoms point to physical failure (clicking, not detected at all, heat), say so and stop before risky steps. If the data is valuable, recommend a professional data recovery service.
Output format:
1. Likely cause (2-3 sentences)
2. Step table: Step | Command | What it does | Risk | Expected result
3. If this fails: 2-3 next options
End by listing your assumptions and any missing information.Example output
How to use this prompt
- Fill in the USB symptom and what you want to recover or achieve.
- Paste the prompt into Cursor chat or another AI assistant.
- Answer its questions about Windows version, file system and backups.
- Run the Safe steps first, paste the output back, and only continue once your data is copied off.
- Who it’s for:
- Developers and Windows users fixing a USB drive from the command line
- What you get:
- An ordered, risk-labeled command plan to diagnose the drive, recover your files and, only afterwards, repair or reformat it.
Use cases
- A USB stick shows as RAW and Windows asks to format it, but it holds the only copy of trip photos
- Folders look empty on a flash drive after it was used on a shared PC
- A drive shows the wrong capacity after being used as a bootable installer
- Checking a work USB drive for file system errors before reusing it
Works well with
- Cursor chat: keep it in propose-only mode so the agent never runs disk commands itself
- Claude or ChatGPT: good at reading pasted command output and adjusting the next step
Try another example
The same prompt filled in for a different situation.
Tips and common edits
Why this works
- Forcing read-only steps first and labeling DESTRUCTIVE commands stops the most common mistake: formatting before recovering data.
- Asking for expected output per step lets you compare results and catch problems before moving on.
- Banning invented switches and pointing to /? keeps commands accurate across Windows versions.
Use when a USB stick shows as RAW, asks to be formatted or hides files. Have the drive letter and Windows version ready. Works in Cursor chat, ChatGPT, Claude or Gemini.
Common edits
- Swap Windows for macOS or Linux and ask for Terminal commands such as diskutil or lsblk instead.
- Narrow the file types in the goal (for example .docx or .mp4) so the recovery step filters for them.
Reuse it: Use in a workflowAdapt in the builder
Prompt details
- By
- Prompts-GPT editors
- Published
Did this prompt work?
More like this
Recover from Git commit or branch mistakes safely
Step-by-step terminal commands to fix commit mix-ups without losing uncommitted changes. Use it right after pushing or committing to the wrong branch.
Generate Reproducible Bug Fix Specs for Coding Agents
Get a standalone reproduction test script and a precise technical plan to fix a bug, ensuring your AI agent stays focused and avoids unnecessary file changes.
Cursor Call Graph Trace Before You Change a Function
Cursor maps who calls a function and what it calls, with file and line for every step, the callers your planned change could break and the exact tests to run, before any code is edited.
Paste a Bug Report, Get a Test-First Fix in Any AI Chat
Get a failing test that reproduces your pasted bug, the root cause, the smallest fix as a diff and its risks, in any chat assistant with no repository access needed.
Triage sudden metric spikes for event tracking bugs
Diagnose whether an unexpected surge in product analytics is real user activity or broken telemetry. Use this before sharing anomalous growth numbers.
Create Error Handling Contracts for AI Agents
This prompt transforms raw stack traces into structured error envelopes that provide agents with specific remediation steps and valid parameter constraints for self-correction.
- Turn Sentry Errors into Reproducible Codex Test Cases
- Speed Up a Slow Windows Laptop or Mac with Safe Step-by-Step Fixes
- Explain Any Regex Token by Token with Matching and Failing Examples
- Get Socratic Coding Hints in Three Levels Before Seeing the Full Solution
- Resolve a Git Merge Conflict and Keep What Both Branches Intended
- Root-Cause Bug Fix With a Failing Test and a Minimal Patch