Guard rail
Guard rail, guardrails, or protective guarding, in general, are a boundary feature and may be a means to prevent or deter access to dangerous or off-limits areas while allowing light and visibility in a greater way than a fence.  Common shapes are flat, rounded edge, and tubular in horizontal railings, whereas tetraform spear-headed or ball-finialled are most common in vertical railings around homes.  Park and garden railings commonly in metalworking feature swirls, leaves, plate metal areas and/or motifs particularly on and beside gates.
High security railings (particularly if in flat metal then a type of palisade) may instead feature jagged points and most metals are well-suited to anti-climb paint.
A handrail is less restrictive on its own than a guard rail and provides support.
Guardrails also apply in a technology context.

Public safety
A Guard rail is a barrier or stationary fence that is designed for the purpose of fall protection. It functions by preventing people from stepping over the edges of roads.
Road Barriers and Fences are designed so that dangerous spaces on the sides of roads are prevented from accessing. They are declared as off-limits areas while permitting light and visibility. Fences avert automobiles from tumbling off cliffs or running off the road or on the opposite side.
Guard Rails or Fences can also be used as momentary barriers to channel traffic in the chosen direction.Many public spaces are fitted with guard rails as a means of protection against accidental falls. Any abrupt change in elevation where the higher portion is accessible makes a fall possible. Due to this responsibility and liability, rails are placed to protect people using the premises. Guardrails in the US are generally required by code where there is a drop of 30 inches (0.76 m) or more.
Examples of this are both architectural and environmental. Environmental guard rails are placed along hiking trails where adjacent terrain is steep. Railings may also be located at scenic overlooks.
Guard rails in buildings can be numerous, and are required by building codes in many circumstances. Handrails along stairways may be supported by balusters forming a balustrade, and catwalks (a type of footbridge) and balconies are also lined with them. An example of a common residential guard rail (US) handrail (Brit.) is a wood railing around a deck or patio. In the US this is typically built on-site from pressure treated lumber thus featuring a simplistic design of vertical baluster spaced every 3.5 inches (8.9 cm) demonstrating compliance with Building Codes (Standards).
Cable railings typically use stainless steel cables strung horizontally. Glass balusters and glass panels open the view while still providing safety, as at the Grand Canyon Skywalk. With the increasing popularity of composite lumber for decking, manufacturers, like TimberTech are providing composite railing components. Wrought iron is another choice that is traditional and sturdy. Decorative examples are considered ironwork.
Building codes also require that no opening in a guard be of a size such that a 4-inch (10 cm) sphere may pass. There are three exceptions according to the 2003 International Building Code Section 1012.3 which allow openings to not exceed 8 or 21 inches (20 or 53 cm) depending on occupancy groups or special areas.
A major architect imaginatively used handrails representing social stability, Alvar Aalto. The guard rails of an observation tower such as the Space Needle or Eiffel Tower become exaggerated to the point of becoming a fence or cage. This is also done on bridges and overpasses to prevent accidents and suicides.

Facility safety
The majority of safety guardrails used in industrial workplaces are made from fabricated steel. Steel guardrail was originally developed by Armco (The American Rolling Mill Company) in 1933 as highway guardrail but is often used in the factories and warehouses of the industrial sector, despite not being intended for this application. Simultaneously, another version of steel guardrail was developed by Kee Clamp Steel for restraining cattle in the agriculture industry, this was released in 1934 and, like Armco guardrail, is still often used in industrial environments. Box beam steel and I-beam steel are other examples of fabricated steel commonly used to make safety guardrails.
As governments around the world courted the voting power of working people and trade unions in the 1980s, the health and safety rights of workers became of greater importance. This set the governmental procedures in motion that would see a flurry of regulations and legislation around workplace safety being introduced in industrialized countries in the 1990s. In the US and UK, these introductions, combined with the demonstrable success of the Occupational Safety and Health Act 1970 (US), and Health and Safety at Work Act 1974 (UK), led to workplace safety being taken more seriously at industrial facilities. Businesses worldwide began to see the value of effective workplace safety, in both the direct commercial sense of protecting assets, but also in the improved productivity levels of a protected workforce. Part of this increase in desire for industrial workplace protection, was a growth in demand for safety guardrails.
In the US, under OSHA Standard 1910.28(b)(15), employees who work on surfaces that are 4 feet (1.2 m) or higher off of the ground must have personal fall protection systems in place, such as handrails or guardrails. Although the OSHA standard calls for a guardrail or guardrail system to protect workers on elevated work areas, current industry terminology would refer to that type of safety system as a handrail system or safety rail system.
The term "guardrail" as used in industry and distribution facilities refers to floor mounted systems consisting of horizontal rails attached to upright posts that resemble outdoor highway guardrail. The facility safety guardrails control in-plant vehicular traffic and protect areas where errant vehicle contact may cause harm to property or personnel. Common uses for guardrail systems may be along an aisle or building wall. Often guardrails are placed around equipment installations to prevent inadvertent contact from lift trucks. The guardrail provides a safety barrier preventing lift trucks or other in-plant vehicles from traveling into equipment, building walls, or personnel.   
There are different types of "industrial" or "facility safety" guardrail systems, each with its own advantages.

Types of guardrail
Steel Ribbed Rail
The most common industrial or facility safety guardrail systems are constructed of steel, where the upright posts are made of heavy wall steel tubing-either round or square, with heavy gauge ribbed steel rails mechanically attached to the uprights by bolts or other fasteners. The uprights may be welded to baseplates and anchored to the floor, or set and concreted into the floor. In industrial and distribution facilities the steel guardrail systems provide solid protection for property and personnel by restricting and controlling where in-plant vehicular traffic may operate. These guardrail systems also serve as a warning for people to be aware of hazardous in facility vehicular traffic. Some facility safety steel guardrail systems utilize one horizontal rail, where others employ two or three rails. While a single rail safety guardrail located some 15 inches (38 cm) above floor level may be sufficient to control vehicle traffic, it could present a trip hazard to pedestrians since it is not as noticeable as a double or triple guardrail system where the top rail is some 40 inches (100 cm) above the floor level.
Manufacturers produce several grades of steel safety guardrail. Each grade is suited to a different application which may be determined by size and type of vehicles used in the facility, the volume of traffic to be controlled, or the value/risk associated with the areas being guarded.

Polymer Guardrail
In 1992 a yellow polymer cover sleeve for steel guardrails was introduced by a Detroit-based company which enhanced the visibility of steel safety guardrails in industrial environments and removed the need for continual repainting. This polymer cover was the beginning of polymer guardrail in the industrial environment. At the turn of the 21st century, several companies developed safety products constructed with polymer designed specifically for industrial environments and in 2001 a dedicated industrial alternative to steel guardrail was invented by a British-based company, and thus the first fixed flexible polymer safety guardrail was introduced to the market. In the early 2000s, an Italian company added a version of a polymer bumper providing small bumpers for walls and equipment in the food industry. A Belgian company also introduced a flexible barrier in 2010 and in 2014 a US based company introduced a hybrid polymer-steel guardrail for industrial environments.There are many types of polymer used in manufacturing safety guardrail. Polymer grains may be blended as part of the production process in order to enhance the natural properties of polymer in different ways. The most common types of polymer used are: polyethylene, polypropylene, and polyvinyl chloride (PVC). Using these types of polymer, there are three basic design philosophies for polymer guardrails:

Impact Dispersal, which applies multi-component engineering to enable guardrails to bend on impact, absorbing and dispersing energy, before returning to their original shape.
Hybrid, which features a steel core encased in polymer.
Central Fix, which utilizes a solid polymer post fixed into the ground with cement and steel subterranean fixings.The Polymer Impact Dispersal Safety Guardrail design offers an advantage over steel guardrails. Steel guardrails, if impacted with sufficient energy, will permanently deform and require repair or replacement to the impacting vehicle, the guardrail itself, and even the floor substrate.  Where the Impact Dispersal Safety Guardrail design allows the guardrail to bend on impact, disperse the energy, and return to its original shape.  Resulting in no damage to the guardrail or the impacting vehicle.

Test Standards for Industrial or Facility Safety Guardrail
Until 2017 there were no accepted standards for how safety guardrail tests were conducted, or how the results were communicated. In 2017, the BSI (British Standards Institution) published the publicly available specification, PAS 13:2017 Code of Practice for safety barriers used in traffic management within workplace environments with test methods for safety barrier impact resilience (commonly referred to as PAS13). This outlines test method guidelines for comparing like-for-like guardrail products, as well as being the current best practice traffic management procedures for a workplace and providing a standard for the safety guardrails within them.In the US, there is no ANSI (American National Standards Institute) Standard for testing guardrails. Steel guardrail system manufacturers test their systems to withstand impacts from a 10,000-pound (4,500 kg) load moving at four miles per hour (6.4 km/h), whereas manufacturers of polymer safety guardrail systems rate and test their products at varying impact levels due to variation in guardrail product systems they offer, which can range from simple low impact energy pedestrian guardrail systems to high impact energy industrial traffic guardrail systems. In order to standardize testing for both steel and polymer guardrails, the Protective Guarding Manufacturers Association (ProGMA) industry group of the Material Handing Industry (MHI) trade association is currently working with ANSI to develop an industry endorsed testing and reporting standard.

Automotive safety
In traffic engineering, highway guardrail may prevent an errant vehicle from hitting roadside obstacles which may be either man-made (sign structures, culvert inlets, utility poles) or natural (trees, rock croppings), running off the road and going down a steep embankment, or veering off the roadway into oncoming traffic (commonly referred to as a median barrier). Roadside obstacles are typically referred to as fixed objects. A secondary objective is keeping the vehicle upright while deflected along the guardrail. Variables such as motorist speed and vehicle orientation when striking the guardrail are crucial factors in the effectiveness of guardrail performance.The most common type of guardrail in use today is the Blocked-Out W-beam (Strong Post). Strong-post W-beam guardrail consists of wood posts and wood blockouts or steel posts with wood or plastic blockouts. The wood or plastic blockouts reduce or minimize a vehicle snagging on the posts upon impact. In addition, a blockout may be used to increase the offset of guardrail with an obstacle such as a curb.The posts' primary purpose is to maintain the height of the guardrail during the initial stages of post deflection. Maintaining guardrail height also reduces the potential for a vehicle to vault over the guardrail upon initial impact.
The posts also play a role in the amount of resistance and deflection a guardrail may experience during impact. Resistance in a strong post system results from a combination of tensile and flexural stiffness of the rail and the bending and shearing resistance of the posts.One of the main concerns with strong-post W-beam guardrail has been the ability of the system to contain and redirect modern vehicles that have a higher center of gravity along with the increased weight of those vehicles. The problem with this is that a guardrail of the optimum height for a car might not keep a truck from toppling over it, while a motorbike might slip under a higher rail. To address these concerns, significant research and development of a system that could contain and redirect vehicles of varying weights and heights was developed and crash tested (both controlled and simulated). As a result, the Midwest Guardrail System (MGS) was developed and successfully crash tested per NCHRP Report 350 TL-3 criteria. MGS has a higher mounting height, uses larger posts and blockouts as compared to the strong-post W-beam guardrail. One other significant difference is that MGS rail splices occur at mid-span compared to at the posts like the strong-post w-beam guardrail.
In most cases, guardrail would not be able to withstand the impact of a vehicle just by the strength of the individual posts in the area hit by the vehicle. Guardrail functions as a system with the guardrail, posts, connection of the rail to the posts and to each other, and the end anchors (or terminals) all playing an integral role in how the guardrail will function upon impact. Soil conditions, height of rail, presence of curb or dike, weight of impacting vehicle, distance from back of post to hinge point and depth of post within soil can all determine how well the system will function upon impact.
Guardrail is effectively one strong band that transfers the force of the vehicle to the rail elements, posts, and end terminals or anchors.  A run of guardrail must be anchored at each terminating end either by transitioning the rail into a fixed anchor such as a bridge rail or with an end terminal or end anchor placed in the ground or within an embankment.  Newer concrete barriers, while usually strong enough to withstand direct hits by cars, still work on a similar principle in deflecting heavier vehicles such as trucks.
Though they have usually prevented far more serious accidents, guardrail is considered a roadside obstacle as well and transportation engineers must weigh whether placing guardrail will reduce the severity of an impact as compared to what may be impacted if the guardrail were not placed. In general, the minimum length of guardrail with an end anchor at the trailing end and an end terminal on the approach end will be 62.5 to 75 feet (19.1 to 22.9 m) in length. An example would be where an overhead roadside sign structure is placed within what is considered the clear recovery zone — An engineer would need to determine that the structure has a potential to be impacted and the impact of a vehicle with that structure would be much more severe than impacting the guardrail.
Guardrail is intended to deflect. The amount of deflection is dependent on a number of factors some of which include type and weight of impacting vehicle, height the guardrail is placed, type of soil the posts may be embedded within, length of embedment of the posts, and distance of the hinge point to the face of guardrail are just a few. A guardrail that deflects significantly can causes pocketing which has the potential to snag a vehicle which may cause it to flip or roll, or cause the rail to fail allowing a vehicle to  penetrate the guardrail.
Modern installations of guardrail are designed to allow the guiderail to deform under the load of the crash, and safely redirecting a vehicle back onto the roadway at a somewhat shallow angle.  It is important that the approach grades to a guardrail system be very flat (typically 10:1 or flatter) and that grades and fixed objects behind guardrail be placed at a distance so that it will not affect the performance of the guardrail upon impact and deflection.
Absorption is when the force of impact is directly transferred between the vehicle and guardrail, which may cause the end to puncture the vehicle. This is most common where a "whale tail" or blunt end treatment exists. To mitigate this a number of guiderail end treatments exist such as "Extruder end treatments", "eccentric loaders" and "Driveway wrap treatments" which result in blunt ends rarely being left exposed in modern installations.
Lastly, a vehicle can become airborne upon striking a guardrail with a buried end treatment if the slope to which the end anchor is buried is relatively flat (3:1 or flatter), which may negate the purpose of the guardrail, if the vehicle continues beyond the guardrail and strikes the object the guardrail was protecting. Additionally, an airborne vehicle is likely to collide in a manner that the vehicle was not designed for, increasing the risk of failure in the vehicle's collision safety systems. Guardrail will have some give and deflection upon impact. The amount of deflection depends on many factors of which speed and weight of vehicle, type of guardrail installed, height of rail, length of posts, soil conditions and a number of other factors can all play a role. Guardrail must be installed so that it is not so rigid that the rail will fail upon impact or the posts will snap off at the point where they are embedded within the ground.
Transportation engineers limit the amount of guardrail placed as much as possible, as guardrails should only be placed when the roadside conditions pose a greater threat than the guardrail itself. In fact, in the hierarchy of five roadside safety treatments, shielding with guardrails ranks fourth. Therefore, while guardrails are often added as a retrofit to existing roads, newer roads are designed to minimize roadside obstacles, whether that may include aligning a road on a smoother curve or filling in a ravine which would eliminate the need for guardrail altogether. In addition to new research into end treatments, public awareness among both drivers and engineers has been gradually reducing injuries and fatalities due to guardrails.
There are four general types of guardrail, ranging from weakest and inexpensive to strongest and expensive; cable and wood posts, steel and wood/metal posts, steel box-beam, and concrete barriers. While cheaper guardrail is the weakest, often being destroyed from the impact of a light vehicle, it is inexpensive and quick to repair, so this is frequently used in low-traffic rural areas. On the other hand, concrete barriers can usually withstand direct hits from a larger variety of vehicle types, making them well suited for use on high volume routes such as freeways. While rarely damaged, they would be considerably more expensive and time-consuming to repair. Concrete barriers are frequently installed in the median, being expected to withstand frequent impacts from both sides, while the shoulders of the road often have cheaper guardrail. Although the use of concrete barriers on the right side of highway is becoming a much for frequent occurrence in areas where guardrail may be sustaining frequent impacts and the ability for maintenance repairs may be restricted by the general area or work windows due to high traffic volumes for most of the day.

Traffic dangers
In cities occasionally pedestrian railings (and barriers) are installed at the immediate side of a roads. However, cyclists have died when crushed against them by motor vehicles. Close "safety barriers" to roads have been found to increase the chances of injury to pedestrians for a number of reasons including increasing inattention of drivers and pedestrians. For these reasons some councils in the United Kingdom have removed their pedestrian railings. This was after London's Royal Borough of Kensington and Chelsea did so and found that the rate of injury to pedestrians decreased three times faster than elsewhere in the city.The removal of barriers divorcing wheeled traffic from pedestrians is an essential of the shared space paradigm and philosophy in urban design. Security barriers have been introduced on a number of the world's major bridges and around key areas of congregation.

Railways
Railway trackage has guard rails (aka check rails) to guide wheels through possible catch points on turnouts or diamonds.  Similarly, guard rails may be installed inside the innermost running rails on very sharp curves.  The other most common usage is to prevent damage to other structures, especially bridges, in a derailment.

Technology
In a technology context, a guardrail is an artifact that defines the boundaries in which technology change can be executed in a manner that is aligned with organisational strategy, risk, architecture, operational and cyber security requirements.Examples of technology guardrails are:

Principles
Policies
Strategies
Technical Standards
Patterns
Guidelines
Reference Architectures (conceptual, logical, physical)Each of these guardrails constrain what technology teams can do within approved boundaries (the scope of the guardrail).  For example, a technology standard may define a certain database as the standard to use within an organisation. The approved standard would have a commercial agreement, operational and delivery capability established, functional and non-functional fit for purpose assessments undertaken, and a cyber security assessment completed.  Technology delivery teams are constrained by the Guardrail to use that particular database technology, but can do so confidently for the scenarios in which usage has been defined and approved.  If a technology delivery team chose a different database technology that is not defined within the technology standards, they could be introducing commercial, organisational or operational risk as the pre-requisite due diligence has not been undertaken.

See also
References
External links

Roadside Hardware Policy and Guidance – United States Federal Highway Administration
Glass Railing Building Codes
Protective Guarding Manufacturers Association (ProGMA)