Skip to main content

Custom Fields

NetBox administrators can extend NetBox's built-in data model by adding custom fields to most object types. See the custom fields documentation for more information.

Fields

Model(s)

Select the NetBox object type or types to which this custom field applies.

Name

The raw field name. This will be used in the database and API, and should consist only of alphanumeric characters and underscores. (Use the label field to designate a human-friendly name for the custom field.)

Label

An optional human-friendly name for the custom field. If not defined, the field's name attribute will be used.

Group Name

If this custom field should be grouped with others, specify the name of the group here. Custom fields with no group defined will be ordered only by weight and name.

Type

The type of data this field holds. This must be one of the following:

TypeDescription
TextFree-form text (intended for single-line use)
Long textFree-form of any length; supports Markdown rendering
IntegerA whole number (positive or negative)
BooleanTrue or false
DateA date in ISO 8601 format (YYYY-MM-DD)
URLThis will be presented as a link in the web UI
JSONArbitrary data stored in JSON format
SelectionA selection of one of several pre-defined custom choices
Multiple selectionA selection field which supports the assignment of multiple values
ObjectA single NetBox object of the type defined by object_type
Multiple objectOne or more NetBox objects of the type defined by object_type

For object and multiple-object fields only. Designates the type of NetBox object being referenced.

For object and multi-object custom fields, a filter may be defined to limit the available objects when populating a field value. This filter maps object attributes to values. For example, {"status": "active"} will include only objects with a status of "active."

warning

This setting is employed for convenience only, and should not be relied upon to enforce data integrity.

Weight

A numeric weight used to override alphabetic ordering of fields by name. Custom fields with a lower weight will be listed before those with a higher weight. (Note that weight applies within the context of a custom field group, if defined.)

Required

If enabled, this custom field must be populated with a valid value for the object to pass validation.

Unique

If enabled, each object must have a unique value set for this custom field (per object type).

Description

A brief description of the field's purpose (optional).

Filter Logic

Defines how filters are evaluated against custom field values.

OptionDescription
DisabledFiltering disabled
LooseMatch any occurrence of the value
ExactMatch only the complete field value

UI Visible

Controls whether the custom field is displayed for objects within the NetBox user interface.

OptionDescription
AlwaysThe field is always displayed when viewing an object (default)
If setThe field is displayed only if a value has been defined
HiddenThe field is not displayed when viewing an object

UI Editable

Controls whether the custom field is editable on objects within the NetBox user interface.

OptionDescription
YesThe field's value may be changed when editing an object (default)
NoThe field's value is displayed when editing an object but may not be altered
HiddenThe field is not displayed when editing an object

Default

The default value to populate for the custom field when creating new objects (optional). This value must be expressed as JSON. If this is a choice or multi-choice field, this must be one of the available choices.

Choice Set

For selection and multi-select custom fields only, this is the set of choices which are valid for the field.

Cloneable

If enabled, values from this field will be automatically pre-populated when cloning existing objects.

Minimum Value

For numeric custom fields only. The minimum valid value (optional).

Maximum Value

For numeric custom fields only. The maximum valid value (optional).

Validation Regex

For string-based custom fields only. A regular expression used to validate the field's value (optional).