A possible meaning is someone may be beautiful on the outside, their character that is inside, and more meaningful may not be attractive.
First found in a work by Sir Thomas Overbury, 1613: “All the carnall beauty of my wife, Is but skin deep.”