# NetBox Configuration (/docs/netbox/v4.3/configuration)



## Configuration File [#configuration-file]

NetBox's configuration file contains all the important parameters which control how NetBox functions: database settings, security controls, user preferences, and so on. While the default configuration suffices out of the box for most use cases, there are a few [required parameters](/netbox/v4.3/configuration/required-parameters/) which **must** be defined during installation.

The configuration file is loaded from `$INSTALL_ROOT/netbox/netbox/configuration.py` by default. An example configuration is provided at `configuration_example.py`, which you may copy to use as your default config. Note that a configuration file must be defined; NetBox will not run without one.

<Callout type="info" title="Customizing the Configuration Module">
  A custom configuration module may be specified by setting the `NETBOX_CONFIGURATION` environment variable. This must be a dotted path to the desired Python module. For example, a file named `my_config.py` in the same directory as `settings.py` would be referenced as `netbox.my_config`.

  To keep things simple, the NetBox documentation refers to the configuration file simply as `configuration.py`.
</Callout>

Some configuration parameters may alternatively be defined either in `configuration.py` or within the administrative section of the user interface. Settings which are "hard-coded" in the configuration file take precedence over those defined via the UI.

## Dynamic Configuration Parameters [#dynamic-configuration-parameters]

Some configuration parameters are primarily controlled via NetBox's admin interface (under Admin > Extras > Configuration Revisions). These are noted where applicable in the documentation. These settings may also be overridden in `configuration.py` to prevent them from being modified via the UI. A complete list of supported parameters is provided below:

* [`ALLOWED_URL_SCHEMES`](/netbox/v4.3/configuration/security/#allowed_url_schemes)
* [`BANNER_BOTTOM`](/netbox/v4.3/configuration/miscellaneous/#banner_bottom)
* [`BANNER_LOGIN`](/netbox/v4.3/configuration/miscellaneous/#banner_login)
* [`BANNER_TOP`](/netbox/v4.3/configuration/miscellaneous/#banner_top)
* [`CHANGELOG_RETENTION`](/netbox/v4.3/configuration/miscellaneous/#changelog_retention)
* [`CUSTOM_VALIDATORS`](/netbox/v4.3/configuration/data-validation/#custom_validators)
* [`DEFAULT_USER_PREFERENCES`](/netbox/v4.3/configuration/default-values/#default_user_preferences)
* [`ENFORCE_GLOBAL_UNIQUE`](/netbox/v4.3/configuration/miscellaneous/#enforce_global_unique)
* [`GRAPHQL_ENABLED`](/netbox/v4.3/configuration/graphql-api/#graphql_enabled)
* [`JOB_RETENTION`](/netbox/v4.3/configuration/miscellaneous/#job_retention)
* [`MAINTENANCE_MODE`](/netbox/v4.3/configuration/miscellaneous/#maintenance_mode)
* [`MAPS_URL`](/netbox/v4.3/configuration/miscellaneous/#maps_url)
* [`MAX_PAGE_SIZE`](/netbox/v4.3/configuration/miscellaneous/#max_page_size)
* [`PAGINATE_COUNT`](/netbox/v4.3/configuration/default-values/#paginate_count)
* [`POWERFEED_DEFAULT_AMPERAGE`](/netbox/v4.3/configuration/default-values/#powerfeed_default_amperage)
* [`POWERFEED_DEFAULT_MAX_UTILIZATION`](/netbox/v4.3/configuration/default-values/#powerfeed_default_max_utilization)
* [`POWERFEED_DEFAULT_VOLTAGE`](/netbox/v4.3/configuration/default-values/#powerfeed_default_voltage)
* [`PREFER_IPV4`](/netbox/v4.3/configuration/miscellaneous/#prefer_ipv4)
* [`RACK_ELEVATION_DEFAULT_UNIT_HEIGHT`](/netbox/v4.3/configuration/default-values/#rack_elevation_default_unit_height)
* [`RACK_ELEVATION_DEFAULT_UNIT_WIDTH`](/netbox/v4.3/configuration/default-values/#rack_elevation_default_unit_width)

## Modifying the Configuration [#modifying-the-configuration]

The configuration file may be modified at any time. However, the WSGI service (e.g. Gunicorn) must be restarted before these changes will take effect:

```text
$ sudo systemctl restart netbox
```

Dynamic configuration parameters (those which can be modified via the UI) take effect immediately.
