Dynamic Modules

Overview

F5 NGINX Plus uses a modular architecture. New features and functionality can be added with software modules, which can be plugged into a running NGINX Plus instance on demand. Dynamic modules add functionality to NGINX Plus such as geolocating users by IP address, resizing images, and embedding NGINX JavaScript njs or Lua scripts into the NGINX Plus event‑processing model. Modules are created both by NGINX and third‑party developers.

NGINX Plus allows features to be plugged in on demand

Dynamic modules are shared object files (.so) that can be loaded at runtime using the load_module directive in the NGINX configuration.

NGINX maintains the official NGINX Plus repository, which also provides packaged binaries for both NGINX‑authored and NGINX‑certified community dynamic modules. All modules in this repository are fully tested to ensure full compatibility with NGINX Plus.

For module‑specific installation and usage instructions, select the corresponding package name in the table.

Name Description Package name
Brotli Brotli compression support with modules for dynamic compression and for serving pre-compressed .br files. nginx-plus-module-brotli
Encrypted-Session AES-256 based encryption/decryption of NGINX variables. nginx-plus-module-encrypted-session
FIPS Status Check Verifies if OpenSSL is operating in FIPS mode. nginx-plus-module-fips-check
GeoIP Enables IP-based geolocation using the precompiled MaxMind databases. nginx-plus-module-geoip
GeoIP2 Uses MaxMind GeoIP2 for enhanced geolocation. nginx-plus-module-geoip2
Headers-More Extends the NGINX Headers module to modify request and response headers. nginx-plus-module-headers-more
HTTP Substitutions Filter Enables regex and string-based substitutions in response bodies. nginx-plus-module-subs-filter
Image-Filter Adds on-the-fly support for JPEG, GIF, PNG, and WebP image resizing and cropping. nginx-plus-module-image-filter
Lua Embeds Lua programming language. nginx-plus-module-lua
NGINX Developer Kit Provides helper macros for module development. nginx-plus-module-ndk
njs Scripting Language Adds JavaScript-like scripting for advanced server-side logic in NGINX configuration file. nginx-plus-module-njs
OpenTelemetry Adds distributed tracing support via OpenTelemetry. nginx-plus-module-otel
Perl Integrates Perl scripting for advanced customization. nginx-plus-module-perl
Phusion Passenger Application server for Node.js, Python, Ruby. nginx-plus-module-passenger
Prometheus-njs Converts NGINX Plus metrics into Prometheus format. nginx-plus-module-prometheus
RTMP Adds streaming capabilities (RTMP, HLS, MPEG-DASH, FFmpeg support). nginx-plus-module-rtmp
Set-Misc Adds set_* directives for scripting (extend NGINX Rewrite module). nginx-plus-module-set-misc
SPNEGO for Kerberos Adds support for GSS‑API based SPNEGO/Kerberos authentication. nginx-plus-module-auth-spnego
XSLT Applies XSLT transformations to XML responses. nginx-plus-module-xslt

Community Dynamic Modules

Besides the modules provided in the official repository, a wide range of third-party modules is available through community-driven projects such as Awesome NGINX GitHub project. Many of these modules can be compiled as dynamic modules and used with your NGINX Plus or NGINX Open Source deployments.

NGINX Certified Partner Dynamic Modules

In addition to the modules authored by NGINX and community third‑party developers, NGINX Certified Partner Modules are available for purchase from commercial third parties. Certified Modules are distributed and supported by their authors. NGINX has tested the modules extensively and certifies that they do not interfere with standard NGINX Plus functionality.

NGINX Certified Partner Modules can be found on the F5 Dynamic Modules page.

Prerequisites

To get started using dynamic modules, first install the latest NGINX Plus release, following the installation instructions. Dynamic modules are supported since NGINX Plus Release 9.

Getting Started with the Dynamic Modules Repository

You can access and install the modules from the NGINX Plus repository using standard package management tools such as apt, dnf, pkg, yum, or zypper.

Displaying the List of Available Modules

To see the list of available modules, run this command (for Debian and Ubuntu):

apt update && \
apt-cache search nginx-plus-module

The output of the command:

nginx-plus-module-auth-spnego/stable
  NGINX Plus 3rd-party kerberos authentication dynamic module

nginx-plus-module-brotli/stable
  NGINX Plus 3rd-party brotli compression dynamic modules

nginx-plus-module-encrypted-session/stable
  NGINX Plus 3rd-party encrypted session dynamic module

nginx-plus-module-fips-check/stable
  NGINX Plus 3rd-party FIPS status check dynamic module

nginx-plus-module-geoip/stable
  NGINX Plus GeoIP dynamic modules

nginx-plus-module-geoip2/stable
  NGINX Plus 3rd-party GeoIP2 dynamic modules

nginx-plus-module-headers-more/stable
  NGINX Plus 3rd-party headers-more dynamic module

nginx-plus-module-image-filter/stable
  NGINX Plus image filter dynamic module

nginx-plus-module-lua/stable
  NGINX Plus 3rd-party Lua dynamic modules

nginx-plus-module-ndk/stable
  NGINX Plus 3rd-party NDK dynamic module

nginx-plus-module-njs/stable
  NGINX Plus njs dynamic modules

nginx-plus-module-opentracing/stable
  NGINX Plus 3rd-party OpenTracing dynamic module
  
nginx-plus-module-otel/stable
  NGINX Plus OpenTelemetry dynamic module

nginx-plus-module-passenger/stable
  NGINX Plus 3rd-party Passenger dynamic module

nginx-plus-module-perl/stable
  NGINX Plus Perl dynamic module

nginx-plus-module-prometheus/stable
  NGINX Plus Prometheus exporter NJS module

nginx-plus-module-rtmp/stable
  NGINX Plus 3rd-party RTMP dynamic module

nginx-plus-module-set-misc/stable
  NGINX Plus 3rd-party set-misc dynamic module

nginx-plus-module-subs-filter/stable
  NGINX Plus 3rd-party substitution dynamic module

nginx-plus-module-xslt/stable
  NGINX Plus xslt dynamic module

The command output also includes an optional debugging symbols package available for each module, for example, nginx-plus-module-njs-dbg. These packages are intended for troubleshooting and diagnostics and should be installed only in debugging or development environments. For more information, see Debugging NGINX.

Installing and loading the module

To install a package, for example, NGINX JavaScript (njs) dynamic modules for Ubuntu, run the command in a terminal:

sudo apt update && \
sudo apt install nginx-plus-module-njs

Then you include the load_module directive in the NGINX Plus configuration file for each dynamic module. The path to the dynamic modules default directory depends on your operating system:

  • /usr/lib64/nginx/modules/ for most Linux operating systems
  • /usr/lib/nginx/modules for Debian, Ubuntu, Alpine
  • /usr/local/etc/nginx/modules for FreeBSD

For example, to enable the njs dynamic modules after the installation of the nginx-plus-module-njs package:

  • in a text editor, open the NGINX Plus configuration file:

    • /etc/nginx/nginx.conf for Linux
    • /usr/local/etc/nginx/nginx.conf for FreeBSD
  • on the top-level (or the “main” context, before any http or stream blocks), specify the path to the target .so file with the load_module directive:

    load_module modules/ngx_http_js_module.so;
    load_module modules/ngx_stream_js_module.so;
    
    http {
        #...
    }
    
    stream {
        #...
    }

Caveats

Certain dynamic modules may be unavailable on specific operating system versions due to platform limitations. For detailed compatibility information, see the NGINX Plus Technical Specifications.

Compiling Your Own Dynamic Modules

To compile your own dynamic modules, see the Compiling Third-Party Dynamic Modules for NGINX Plus blogpost.

Uninstalling a Dynamic Module

To uninstall a dynamic module, see the Uninstalling a dynamic module article.

See Also