A neat trick is to start by lightly tapping the gasket with a rubber mallet or a hammer. The gasket material will expand and come off the surface quite easily.
In the case of stubborn gaskets, silicon compounds etc. the use of a razor blade and/ or an X-Acto knife is essential for removing gasket material from mating surfaces of engine parts.
Hold the razor blade at a 45-degree angle and begin to scrape the old gasket off.