Most starships in Star Trek use defensive shield technology to protect against enemy attacks. As the shields take hits from enemy fire, they become weakened, and effects from enemy attacks bleed through with greater frequency.
Shields are usually depicted as a bubble surrounding a starship that is visible only when actively resisting an attack. During the Dominion War, shields seemed to conform to the hulls of the starships projecting them.
Most transporters cannot beam through combat-grade defensive shields.
According to an engineering display from Star Trek: Generations, a shield involves a "graviton field" (with a strength measured in meaningless units) and oscillates at a specific frequency, although shield frequency is known to be adjustable.
The shields of starships are typically capable of withstanding several attacks from opposing ships of similar size and technology. Blocking incoming fire steadily depletes the protective capacity of a shield, the reduction usually being described as a percentage of its full capacity.,
The size, shape, and operating frequency of a shield are typically adjustable. All of these factors can affect a shield's performance against various types of attack.
Shields are also directional, with shields facing different directions being referred to either by facing or a number, such as the "forward shield" or "number 4 shield". Presumably different emitters project the shield from different sides of the ship, and the emitters on the side taking fire do the bulk of the work of resisting an attack.
Star Trek shields handle radiant energy far more effectively than collisions with massive objects.
Even with fully operational shields, it is not unusual for ships to sustain some internal damage when hit by weapons fire.
Shields operate at a specific frequency. This allows friendly weapons fire originating from the shielded ship to pass through. If an attacker can determine the target's shield frequency, as occurred in Generations when the Klingons learned the operating frequency of the Enterprise's shields, their shots will also pass through unimpeded. Many species -- such as the Borg, Vidiians, and Voth -- either explicitly or implicitly overcome shields in this manner. Determining the target's shield frequency is the difficult part: Federation sensor technology isn't able to remotely determine the frequency of an operating shield; civilizations like the Borg are not so limited.
The effectiveness of countermeasures depends greatly on the competence of the tactical officer and bridge crew. In "Equinox", Tuvok altered the shield frequences without prompting from Janeway. However, in Generations, Riker did not order shield frequency rotation despite previous experience with the Borg, allowing an obsolete Klingon Bird of Prey to pour fire through their compromised shield.
In TNG "The Wounded", Chief O'Brien exploited a vulnerability in USS Phoenix's shields to transport himself aboard. The Phoenix needed to "blink" its shields at predictable intervals to use a high-powered sensor sweep, and the blink provided an opportunity to transport onto the ship.
Voyager's Emergency Medical Hologram was able to monitor the shield frequency of the ship from sickbay in VOY "Equinox". There is no known reason why tactical information should be available to a medical officer in the sickbay. Technically, the Doctor is part of the ship's computer anyway, so he shouldn't need to look up information on a display.
Shields frequently fail to perform well against new weaponry. For instance, Federation shields failed to stop Dominion phased polaron beams in early combat encounters, but Federation engineers were able to modify their shield systems to provide protection in later encounters.
In TNG "Hero Worship", Geordi diverted fusion power to the shields and doubled the Enterprise's shield strength. Diverting warp power to the shields would provide at least this much, if not far more powerful shields. Of course, such diverted power becomes unavailable for weaponry or propulsion.
In Kirk's era, it was standard practice to raise shields on approach of an unidentified vessel. "Defense fields" automatically engaged, possibly to prevent indiscriminate transporter use. However, main shielding was not consistently shown to activate automatically, often requiring action by the tactical officer. It is unknown to what degree "defense fields" exist in Picard's era.
Shields can be extended from one vessel to another, as in TOS "Mudd's Women", TNG "The Defector", DS9 "Defiant", and VOY "Equinox". When extended in this fashion, however, the strength of the shield drops significantly, presumably in inverse proportion to the degree by which the shield's surface area increases.
The crew of the Enterprise developed a countermeasure called "shield nutation" to defend against the Borg. When in use, the operating frequency of the shield changes rapidly, preventing the Borg from locking onto the ship and rapidly draining shield power. This modification was briefly successful, but the Borg developed a countermeasure in less than a minute. When under Borg attack, the Enterprise did not return fire while the nutational shield was still operating, suggesting that they are unable to shoot through the shield when it is operating in this mode.