Engineering ethics is the field of system of moral principles that apply to the practice of engineering. The field examines and sets the obligations by engineers to society, to their clients, and to the profession. As a scholarly discipline, it is closely related to subjects such as the philosophy of science, the philosophy of engineering, and the ethics of technology.
As engineering rose as a distinct profession during the 19th century, engineers saw themselves as either independent professional practitioners or technical employees of large enterprises. There was considerable tension between the two sides as large industrial employers fought to maintain control of their employees.
In the United States growing professionalism gave rise to the development of four founding engineering societies: The American Society of Civil Engineers (ASCE) (1851), the American Institute of Electrical Engineers (AIEE) (1884), the American Society of Mechanical Engineers (ASME) (1880), and the American Institute of Mining Engineers (AIME) (1871). ASCE and AIEE were more closely identified with the engineer as learned professional, where ASME, to an extent, and AIME almost entirely, identified with the view that the engineer is a technical employee.
Even so, at that time ethics was viewed as a personal rather than a broad professional concern.:6
When the 19th century drew to a close and the 20th century began, there had been series of significant structural failures, including some spectacular bridge failures, notably the Ashtabula River Railroad Disaster (1876), Tay Bridge Disaster (1879), and the Quebec Bridge collapse (1907). These had a profound effect on engineers and forced the profession to confront shortcomings in technical and construction practice, as well as ethical standards.
One response was the development of formal codes of ethics by three of the four founding engineering societies. AIEE adopted theirs in 1912. ASCE and ASME did so in 1914. AIME did not adopt a code of ethics in its history.
Concerns for professional practice and protecting the public highlighted by these bridge failures, as well as the Boston molasses disaster (1919), provided impetus for another movement that had been underway for some time: to require formal credentials (Professional Engineering licensure in the US) as a requirement to practice. This involves meeting some combination of educational, experience, and testing requirements.
In 1950, the Association of German Engineers developed an oath for all its members titled 'The Confession of the Engineers', directly hinting at the role of engineers in the atrocities committed during World War II.
Over the following decades most American states and Canadian provinces either required engineers to be licensed, or passed special legislation reserving title rights to organization of professional engineers. The Canadian model is to require all persons working in fields of engineering that posed a risk to life, health, property, the public welfare and the environment to be licensed, and all provinces required licensing by the 1950s.
The US model has generally been only to require the practicing engineers offering engineering services that impact the public welfare, safety, safeguarding of life, health, or property to be licensed, while engineers working in private industry without a direct offering of engineering services to the public or other businesses, education, and government need not be licensed. This has perpetuated the split between professional engineers and those in private industry. Professional societies have adopted generally uniform codes of ethics.
Efforts to promote ethical practice continue. In addition to the professional societies and chartering organizations efforts with their members, the Canadian Iron Ring and American Order of the Engineer trace their roots to the 1907 Quebec Bridge collapse. Both require members to swear an oath to uphold ethical practice and wear a symbolic ring as a reminder.
In the United States, the National Society of Professional Engineers released in 1946 its Canons of Ethics for Engineers and Rules of Professional Conduct, which evolved to the current Code of Ethics, adopted in 1964. These requests ultimately led to the creation of the Board of Ethical Review in 1954. Ethics cases rarely have easy answers, but the BER's nearly 500 advisory opinions have helped bring clarity to the ethical issues engineers face daily.
Currently, bribery and political corruption is being addressed very directly by several professional societies and business groups around the world. However, new issues have arisen, such as offshoring, sustainable development, and environmental protection, that the profession is having to consider and address.
Engineers, in the fulfillment of their professional duties, shall hold paramount the safety, health, and welfare of the public— National Society of Professional Engineers, 
A practitioner shall regard the practitioner's duty to public welfare as paramount."— Professional Engineers Ontario, 
Codes of engineering ethics identify a specific precedence with respect to the engineer's consideration for the public, clients, employers, and the profession.
Many engineering professional societies have prepared codes of ethics. Some date to the early decades of the twentieth century. These have been incorporated to a greater or lesser degree into the regulatory laws of several jurisdictions. While these statements of general principles served as a guide, engineers still require sound judgment to interpret how the code would apply to specific circumstances.
The general principles of the codes of ethics are largely similar across the various engineering societies and chartering authorities of the world, which further extend the code and publish specific guidance. The following is an example from the American Society of Civil Engineers:
The paramount value recognized by engineers is the safety and welfare of the public. As demonstrated by the following selected excerpts, this is the case for professional engineering organizations in nearly every jurisdiction and engineering discipline:
Responsibility of engineers
The engineers recognize that the greatest merit is the work and exercise their profession committed to serving society, attending to the welfare and progress of the majority. By transforming nature for the benefit of mankind, engineers must increase their awareness of the world as the abode of humanity, their interest in the universe as a guarantee of overcoming their spirit, and knowledge of reality to make the world fairer and happier. The engineer should reject any paper that is intended to harm the general interest, thus avoiding a situation that might be hazardous or threatening to the environment, life, health, or other rights of human beings. It is an inescapable duty of the engineer to uphold the prestige of the profession, to ensure its proper discharge, and to maintain a professional demeanor rooted in ability, honesty, fortitude, temperance, magnanimity, modesty, honesty, and justice; with the consciousness of individual well-being subordinate to the social good. The engineers and their employers must ensure the continuous improvement of their knowledge, particularly of their profession, disseminate their knowledge, share their experience, provide opportunities for education and training of workers, provide recognition, moral and material support to the schools where they studied, thus returning the benefits and opportunities they and their employers have received. It is the responsibility of the engineers to carry out their work efficiently and to support the law. In particular, they must ensure compliance with the standards of worker protection as provided by the law. As professionals, the engineers are expected to commit themselves to high standards of conduct (NSPE).  11/27/11
Main article: Whistleblower
A basic ethical dilemma is that an engineer has the duty to report to the appropriate authority a possible risk to others from a client or employer failing to follow the engineer's directions. According to first principles, this duty overrides the duty to a client and/or employer. An engineer may be disciplined, or have their license revoked, even if the failure to report such a danger does not result in the loss of life or health.
In many cases, this duty can be discharged by advising the client of the consequences in a forthright matter, and ensuring the client takes the engineer's advice. In very rare cases, where even a governmental authority may not take appropriate action, the engineer can only discharge the duty by making the situation public. As a result, whistleblowing by professional engineers is not an unusual event, and courts have often sided with engineers in such cases, overruling duties to employers and confidentiality considerations that otherwise would have prevented the engineer from speaking out.
There are several other ethical issues that engineers may face. Some have to do with technical practice, but many others have to do with broader considerations of business conduct. These include:
Some engineering societies are addressing environmental protection as a stand-alone question of ethics.
The field of business ethics often overlaps and informs ethical decision making for engineers.
Petroski notes that most engineering failures are much more involved than simple technical mis-calculations and involve the failure of the design process or management culture. However, not all engineering failures involve ethical issues. The infamous collapse of the first Tacoma Narrows Bridge, and the losses of the Mars Polar Lander and Mars Climate Orbiter were technical and design process failures.
These episodes of engineering failure include ethical as well as technical issues.