Biological organisms often have remarkable multifunctionality through intricate structures, such as concurrent shape morphing and stiffness variation in the octopus. Soft robots, which are inspired by natural creatures, usually require the integration of separate modules to achieve these various functions. As a result, the whole structure is cumbersome, and the control system is complex, often involving multiple control loops to finish a required task. Here, inspired by the scales that cover creatures like pangolins and fish, we developed a robotic structure that can vary its stiffness and change shape simultaneously in a highly integrated, compact body. The scale-inspired layered structure (SAILS) was enabled by the inversely designed programmable surface patterns of the scales. After fabrication, SAILS was inherently soft and flexible. When sealed in an elastic envelope and subjected to negative confining pressure, it transitioned to its designated shape and concurrently became stiff. SAILS could be actuated at frequencies as high as 5 hertz and achieved an apparent bending modulus change of up to 53 times between its soft and stiff states. We further demonstrated both the versatility of SAILS by developing a soft robot that is amphibious and adaptive and tunable landing systems for drones with the capacity to accommodate different loads.