LPS/SPS, I wedge a sharp small knife under it, twist and it pops off.
Zoas, I use a slightly larger knife to "scrape" everything off the plug.
Softies, same thing.
If you can, when scraping, try to get bits of the old plug, makes it easier to glue onto something different.
Some corals (mushrooms, some softies) you won't be able to glue, you'll have to rubberband.
Some softies you can glue.
I have a type of kenya tree that drops babies all the time, I glue them onto rocks.
Xenia, not easy to glue.
But like grant778 said, telling the type of coral will help with the answer.