Your hard disk has probably failed.
That’s a fairly common cause of folks running repairs and re-installs.
Which Mac and which model year?
If you have do not have current backups, that’s going to be your first priority, if that data can be recovered. Not repairs or re-installations or such. Failing hard disks can and usually do degrade from sort-of working to sort-of-not working.
Run Diagnostics (newer) or Test (older) on your Mac:
How to use Apple Diagnostics on your Mac - Apple Support
How to use Apple Hardware Test on your Mac - Apple Support
Mavericks is very old, which means this Mac is probably old, which means the hard disk is suspect, and means recovery options can be limited.
If you can get into Recovery, try performing a macOS install on an available-to-be-erased external storage device. That’ll at least let you see if this Mac is mostly-working and the failure isolated to the storage, or if there is a wider problem. And it’ll let you run with a failed internal storage device, pending repair or replacement. That’s if this Mac is mostly still working.
Command-Option-R for Recovery will get you the newest version of macOS compatible with your Mac.
If you cannot get into Recovery, then you’ll want to create a bootable installer on another Mac, and boot that. You’ll need to use a version of macOS that is compatible with your old Mac, and that your new Mac can also use (as the App Store can block incompatible downloads), which can get a little tricky. If you can identify the model and year of both Macs involved, I can better determine which version(s) can be used here, if there are compatible versions.
Depending on the Mac, an SSD upgrade can be feasible, if you might want to try to keep this Mac for a few more years.
Again, Mac model and model year helps with determining the options and alternatives...