You must test it with 14K acid. You can not purchase this and do it on your own. You need a professional that knows what they're doing and looking for.
Use nitric acid to accurately test if an item is real gold. Real gold is insoluble in nitric acid. You can also use a magnet. Real gold is not magnetic.
Real gold is marked on it somewhere on the back or on the clasp of the piece. It will say which kind of gold it is on it in most cases. Also, buy from a jewelry store is best.
I think that your best bet is to take it to a jeweler because any tests that you might try on your own may not be completely accurate and a jeweler would know best.
You can check for a stamp on the jewelry, a piece less then forty years old will be required to have a stamp that identifies the material, such as 14k.
Gold is checked by its weight and making a scratch on it. After scratching if it turns into black then it is artificial,turning to golden colour is the real gold.