Scientists have devised a coating that when scratched heals itself upon exposure to sunlight.
The secret of the material lies in using molecules made from chitosan, which is derived from the shells of crabs and other crustaceans.
In the event of a scratch, ultraviolet light drives a chemical reaction that patches the damage.
The work by University of Southern Mississippi researchers is reported in the journal Science.
They designed molecules joining ring-shaped molecules called oxetane with chitosan.
The custom-made molecules were added to a standard mix of polyurethane, a popular varnishing material that is also used in products ranging from soft furnishings to swimsuits.
Scratches or damage to the polyurethane coat split the oxetane rings, revealing loose ends that are highly likely to chemically react.
In the ultraviolet light provided by the sun, the chitosan molecules split in two, joining to the oxetane's reactive ends.
"In essence you create a scratch, and that scratch will disappear upon exposure to the sun," said Professor Marek Urban, director of the university's school of polymers and high-performance materials.
Professor Urban and graduate student Biswajit Ghosh found that their coatings were able to fully heal themselves in just 30 minutes.
A number of self-healing composites have been developed in recent years, many of which depend on the inclusion of capsules or hollow fibres filled with glue-like materials.
A scratch or crack ruptures the capsules or fibres, and the glue fixes the damage.
Professor Urban says that such approaches are "fairly elaborate and many times simply economically not feasible".
By contrast, the new approach only requires adding a tiny amount of the doctored molecules to the mix.
"There's still work to do, but we're on the right track with the current chemistry - which is not very complicated," said Professor Urban.
"It has tremendous potential for improving the properties of materials."
The well-established nature of polyurethane in such a wide range of manufacturing could see a number of benefits, not least the self-healing car paint job.
"Clearly, there are future applications of this work in the repair of automotive components, which extensively use polyurethane polymers," said Professor Howell Edwards, a chemist at the University of Bradford.