How do I recover lost files from a restarted Mac after terminal work?

URGENT! my mac erased itself but i still have my applications and my phone is fine but my files are lost on my mac and im about to submit my final project please help. it was hot when i switched it off and when i switched it on everything was gone ex. I was working on the terminal and then my iMessage started bugging so I switched off my laptop cause I had been working on the terminal all day and my laptop was getting hot. When I switched it back on everything was gone except for my applications, but the laptop is almost brand new now and I have my final project to submit right now. Please help me guys I need to get my files back immediately and my logins.



[Edited by Moderator]

iPhone 14 Pro Max, iOS 17

Posted on Apr 13, 2025 3:42 AM

Reply
Question marked as Top-ranking reply

Posted on Apr 13, 2025 4:35 PM

The easiest way to recover those lost files to restore a Time Machine "local snapshot" provided it has been less than (about) 24 hours since the event. To restore a "local snapshot" you will be choosing the Mac's startup drive as the data source. It takes all of about two minutes, start to finish.


About Time Machine local snapshots on Mac - Apple Support


Important: Local snapshots are only stored on disks using Apple File System (APFS) when Back Up Automatically is selected in Time Machine settings.

3 replies
Question marked as Top-ranking reply

Apr 13, 2025 4:35 PM in response to Appleuser664_

The easiest way to recover those lost files to restore a Time Machine "local snapshot" provided it has been less than (about) 24 hours since the event. To restore a "local snapshot" you will be choosing the Mac's startup drive as the data source. It takes all of about two minutes, start to finish.


About Time Machine local snapshots on Mac - Apple Support


Important: Local snapshots are only stored on disks using Apple File System (APFS) when Back Up Automatically is selected in Time Machine settings.

Apr 13, 2025 6:37 AM in response to Appleuser664_

Choose Computer from the Finder's Go menu, open your internal drive, and then the Users folder. If there's anything in it other than your home folder and Shared, check those folders for your data; otherwise, search the computer for your files, or restore them from a backup. If you can't find them anywhere, you may need to use data recovery software or contact a professional service.


(259918)

Apr 13, 2025 4:51 PM in response to Appleuser664_

"How do I recover lost files from a restarted Mac after terminal work?: [...]When I switched it back on everything was gone except for my applications, but the laptop is almost brand new now and I have my final project to submit right now. Please help me guys I need to get my files back immediately and my logins."

-------


Finding Lost Files:

If no backup...

A. Try Spotlight Search:

[Hold Down +command + Press: spacebar] > Type a file name > Press return. Anything Pop Up?

Learn More Here: Search with Spotlight on Mac - Apple Support

If you get nothing, then try rebuilding the Spotlight Index. Go Here: Rebuild the Spotlight Index on your Mac - Apple Support


B. Try Safe Mode:

In Safe Mode, login items do not run, and corrupt system files(i.e. caches) are intentionally reset as a way to fix issues. Go here: Start up your Mac in Safe Mode - Apple Support

  1. Boot: in to Safe Mode
  2. Log in: as same user
  3. Wait: 30 seconds
  4. Restart; your Mac
  5. Log in: as same user
  6. Search for the files


C. Try Another User:

Create a new Administrator user, and see if you can see these files through Finder. You'd have to create an Administrator account for this. Go Here: Add a user or group on Mac - Apple Support


As a last resort...

D. Reinstall the macOS:

Finder may have a few bug in it, so to fix that, one option would be to reinstall the macOS to fix any bugs in this app. Nothing would be lost. It's just that misplaced items would be placed back to where they should be and corrupt system files would be replaced by clean files. Go Here: Reinstall macOS - Apple Support. Boot into Recovery Mode (Intel or Silicon).  Important: Prior to installing an update or performing a reinstallation, to prevent data loss, be sure to Back up your Mac with Time Machine.


This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How do I recover lost files from a restarted Mac after terminal work?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.