I have an old metal framed house number that looks like it is embedded in the stucco (see image).
First, use a hammer and chisel to cut the stucco tight to the old sign. Try to undercut at 45 degrees so that when the sign pops off it will not pull any more of the stucco with it. Once you have a clean-edged rectangular depression, fill it flush with a wood block and some stucco product. You want a waterproof patch.
If your new sign is a bit too small you can build a "picture frame" around the sign. Add the frame after mounting the new sign, or attach the sign to a larger thin substrate with the frame as one piece..
Found a lot of details about this classic San Francisco house number here
After understanding the structure, you can see it can usually be removed without force, with some unscrewing of old rusted screws.