A man armed with a gun tried to rob two packets of cigarettes from a Westport dairy.

A West Coast shopkeeper told an attempted robber to get out after he pulled out a gun and demanded two packets of cigarettes.

A police spokeswoman said the incident happened at a superette on Palmerston St in Westport, about 9.50pm on Wednesday.

A man wearing a scarf and sunglasses entered the store, pulled the pistol grip of a hand gun from his trousers and ordered the shopkeeper to hand over two packets of cigarettes.

The shopkeeper told the man to leave and called police. The man then left the store and headed south on Palmerston St, the spokeswoman said.

Anyone with information can call Westport police on 03 789 7339, or contact Crimestoppers anonymously on 0800 555 111.