From Sonic Retro
The Shield, referred to as the barrier (バリア) in Japan, is a power-up that protects the player from harm. When the player runs into an enemy or trap, their character will be knocked backwards and the shield will be lost. Shields offer an extra line of defense before rings would be lost, and first appeared in the original Sega Mega Drive game, Sonic the Hedgehog.
The original shield is a simple blue sphere, to the point wherein Sonic 3D: Flickies' Island (and later games such as Sonic Mania) it is called the blue shield or blue barrier (ブルーバリア). Despite this, it is not always blue - in Knuckles the Echidna in Sonic the Hedgehog 2 the shield is grey, and in Sonic Adventure and Sonic Advance, it is green. An exception to its round design is Sonic Forces, where it takes the form of multiple energy particles, moving in a circular pattern around the player.
In most games, the blue shield offers no additional advantages outside the extra hit point (unlike the shields later provided in Sonic the Hedgehog 3; the Flame Shield, Water Shield and Lightning Shield). The one exception to this rule is in Sonic 3D: Flickies' Island, where the blue shield is impervious to the electric flooring in Gene Gadget Zone.