To buy sunglasses, you need to know your prescription(if you need prescription sunglasses), pupil distance, with or without astigmatism and the width of your face if you are a little bit oversize. It's better for you to buy a pair of sunglasses which is wider than the part of your face.
Ok, it seems that you are going to get yourself a pair of sunglasses ,nice. Anyway, it is true what size of the sunglasses is a problem we face. Generally speaking, there are 3 types, small, medium, large. You could try to figure out what type is suitable for your head size. Just try to ask the sales clerk online to consult for some information. Or if you head size is ok, you can choose medium sized sunglasses.
Do you have any eye exam before in the real store of eyeglasses by the machine? If you have, the size is the one that for the sunglasses. If you do not, you could go to have the eye exam first to get the exact eye size. Then you will know the frame size of you. In order not to get the wrong size which will make you wear uncomfortable, you should better go to have the eye exam first to get the pupillary distance.