Pull plastic and metal wall anchors out cleanly and patch the hole so the wall is ready to repaint.
Back the screw all the way out of the anchor with a screwdriver or drill. The anchor stays gripped in the drywall once the screw is out, ready to be pulled or pushed.
For threaded (self-drilling) anchors, turn them counterclockwise with a screwdriver and they will often back out the way they went in. For ribbed expansion anchors, grip the lip with needle-nose pliers and wiggle and pull straight out. Going slow keeps the surrounding drywall from tearing.
If an anchor is stuck or has wings behind the wall, do not yank — that rips a big chunk of drywall. Instead, hold a screwdriver or punch against the anchor head and tap it with a hammer to push it through the wall into the cavity. This leaves only a small clean hole.
Press lightweight spackle or joint compound into the hole with a putty knife, slightly overfilling it, and scrape it flush. Let it dry, then sand smooth with fine sandpaper. Wide holes may need a self-adhesive mesh patch first.
Spot-prime the patched area so the spackle does not flash through, then touch up with matching wall paint. Priming first keeps the repair from showing as a dull spot once the paint dries.