Here are some basic rules for naming compounds:
Rule 1: When two elements bond and one is a halogen (group 7) atom or oxygen or sulphur, the name ends with the suffix ide, eg. Magnesium Oxide
Rule 2: When three or more elements bond and one is oxygen the name ends with the suffix ate, eg. Copper Sulfate
Rule 3: When three or more elements bond and two of them are hydrogen and oxygen, the name ends in hydroxide, eg. Potassium Hydroxide