Why do my versions not come up? [closed]

I don't know what happened but, I was playing Minecraft and everything was working perfectly. Next day I get on and it made me redownload the game. And all my versions are gone! All my versions are in my versions folder, but when I open my Minecraft launcher and go into "Use Version" nothing is in there?! Please help!

Also, If this is helpful, all my resourcepacks work great. It's just my versions that don't work.

(One last thing, it's only my mod versions. Like Optifine, and Forge.)


Redownloading the launcher will cause this problem. There is a .json file in the .minecraft directory that saves all that information. It has most likely been erased so there is no way to retrieve it but by re-running the installers for optifine and forge will fix your issue.