You want your home to be in its best condition when you sell it. Buyers should be able to say "Wow! I love this house!" Unsightly issues like this can make your property look less beautiful.
There are many options.
The first step is to fix the problem. Specialty cleaners are available that can lift stubborn stains from carpets.
This is true for tile and hardwood. A contractor may be able find a match for the damaged piece and replace it. Contractors can also use other techniques to repair or minimize damage to flooring. There are fillers and colors that can almost make a crack in a hardwood plank appear invisible.
Staging can make damaged flooring less prominent in a room. A well-organized arrangement of furniture, area rug, and other pieces puts the emphasis on the overall decor, rather than the carpet stain.
You can also make other, more affordable improvements like painting to compensate. The walls look brand new, even though buyers may be able to see the chipped hardwood.