Add a field to a content type
Drupal 7 will no longer be supported after January 5, 2025. Learn more and find resources for Drupal 7 sites
- Navigate to the Content types page (Administer > Structure > Content types).
- In the table, locate the row that contains your content type and click the MANAGE FIELDS link. If you can't find the MANAGE FIELDS link, be sure to enable the Field UI module.
- In the Add new field section, enter a label for the field.
- In the Field name field, enter the machine name for the field. You can only use numbers, lower-case letters and the underscore character (_). The node that the machine name is automatically generated and it is not necessary that it be changed.
- In the field type list, select one of the following types. Note that more fields such as 'Date' and 'Location' can be added using Drupal modules. To find modules, click here. For help installing modules, click here.
Text
short text such as a name (limited to 255 characters)
Long text
long, multi-line alphanumeric text such as a biography
Boolean
has one of two values (for example: "yes/no" or "true/false" or "small/large")
List (text)
select from a list of text options (which can be formatted as either a drop-down list or checkboxes)
File
reference to a file (such as a PDF) on the Drupal file system
Image
reference to an image file such as GIF, JPG, PNG on the Drupal file system
Term reference
reference id to an existing Taxonomy Term (or tag)
Integer
a whole number, such as a year (e.g. 2012) or value (e.g. 1, 2, 5, 305); it does not allow decimals.
Float
a number that can use decimals, such as 0.0123456789
Decimal
a number that allows exact decimal values; often used for price or cost (such as $199.99)
List (float)
select from a drop-down list of floats
List (integer)
select from a drop-down list of integers
Long text and summary
same as long text, but with an additional summary text
- In the Widget field, select a widget. The options vary depending on the field type.
- Click Save.
Note: Not all field types are provided by Drupal core. Things like References, Dates, Links, and various other types can be found by filtering on "field" in the module list on drupal.org (or "Content Construction Kit" for Drupal 6). Users of the CCK module in Drupal 6 should note that the node reference and user reference fields are not supported in Drupal 7 core; however, there is a separate References module that provides support for these fields in Drupal 7. In Drupal 7 Entity reference is a good option to use for references because in Drupal 7 most of the things in the core are managed through entity.
Help improve this page
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion