Cop is a very old English word that means to capture or catch. It was soon to become associated with the police, and the copper was born. It's a fair cop.
The American cop may seem at first glance to simply be a shortened version of our copper, but some believe that cop was largely inspired by the fact that the New York police used to flash copper badges at those they apprehended.
Pig was first used as a derogatory term for the police way back in 1811. There is no logical origin story behind the word - it seems simply to have stemmed from the disgusted resentment that some felt towards the long arm of the law. The use of pig went out of fashion until the 1960s, when American students used it as a taunt during their anti-Vietnam war demonstrations.
The Old Bill - The police force as we know it today came into being when the politician Robert Peel introduced the Metropolitan Police Bill in 1829. This legislation set up a formal, uniformed police force who started their first organised patrols on the 29th September, 1829. Their nickname stems from The Bill that created them.
As well as the above, The Peelers and Bobbies, you also had the Bow Street Runners, Flatfoots, The Rozza's/The Roz, The Fuzz, The Sweeney and The Nick (as in you're nicked me ol' china).
as to when the term 'bobby' or 'bobbies on the beat' phased out, as mentioned above the term still remains in some parts of the country and media.