Do I just 2x the size of the file while maintaining it's ratio? Like lets say I want to upload a high res image to instagram? What do I have to do to maintain a very high res image?
Social media sites use their own rules how they mangle photos. They need to try to keep the storage costs low enough to maximize their profits.
You must be somehow important to the media company (for. ex. the biggest owner) to force them behave as you want. Social media companies do not care of ordinary punters, they are only the food - the special one which imagines he is eating.
But you can optimize your images so that their automation causes the least amount of damage (=have certain pixel dimensions, but do exceed them, have certain aspect ratio, have more contrast than needed at your own PC, do not compress it to low quality before uploading) Search for guides. Here's one:
and here's another: