1 December 2020
Phillipa Martin

What is ‘rules as code’?

Rules as code (RaC) takes legislation, regulations and policies and turns them into machine-readable code so they can be understood and interpreted by computers.

Why rules as code? 

Turning rules into machine-readable code provides many benefits for government, citizens and broader society. RaC helps to reduce ambiguity, reduces the difficulty of interpretation and therefore makes it easier for citizens and organisations to comply with the rules. Importantly, it also leads to greater transparency in rules. 

For a full list of benefits, see the OECD’s Cracking the code: Rulemaking for humans and machines (p.39 includes a benefits table).  

Who’s using rules as code? 

Many governments around the world are exploring and implementing RaC — although it’s still definitely an emerging field. 

France was an early adopter, creating the open source OpenFisca  that can be used to support and create RaC. 

New Zealand is also active in this space. Rules as code is part of NZ’s Better Rules program, which brings a new approach to policy and legislation. RaC was also used in creating NZ’s SmartStart, a portal for NZ parents that includes birth registration. 

An example here in Australia is the NSW Government. They’ve created a digital version of the Community Gaming Regulation 2020 and have also produced assets on RaC, including:

More on NSW and rules as code

Rules as code and the Observatory of Public Sector Innovation (OPSI)

The OPSI has a dedicated emerging tech project focused on rules as code. One of the outcomes of that project has been the recent release of OPSI’s report, Cracking the Code. The report provides an introduction to RaC, including benefits, use cases, the effort involved, and general advice and guidelines.  

It’s an extensive report at over 100 pages, and the OPSI does provide a shorter 16-page report, Cracking the Code Highlights

Salsa Digital’s take

Some laws have been in place for many, many years — decades or even centuries! While much legislation has been transformed through amendments, other laws have remained static. RaC provides an excellent opportunity for government transformation, specifically digital transformation. While it’s still an emerging field, it’s clear that there will be significant work in this area in the coming years.

Subscribe to DTIG

Subscribe to our Digital Transformation in Government series to keep up with how technology is transforming government.