> For the complete documentation index, see [llms.txt](https://mongo.webcore.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mongo.webcore.io/reference/fields/string.md).

# String

String fields store Unicode text, utilizing the native Unicode representation for your version of Python. (On Python 2: `unicode`, on Python 3: `str`.)

### Import

`from marrow.mongo.field import String`

### Inherits

`marrow.mongo:`**`Field`**

## Attributes

This field type inherits all [`Field` attributes](https://github.com/marrow/mongo/tree/128b1ec81ec6a48e05a95c32b636deede377854b/reference/field/field.md#attributes) and represents a singular, scalar Unicode string value. In addition to the basic attributes, String fields can automatically strip extraneous whitespace on assignment or perform case normalization, e.g. automatic execution of `str.upper()`, `str.lower()`, or `str.title()`.

### `strip`

Either the boolean literal `True` or a string representing the argument to `str.strip`, that is, the characters to strip.

Default`False`

Added`>=1.1.1`

### `case`

Truthy values (or the string literal `"u"` or `"upper"`) will request uppercase normalization, falsy values (or the literals `"l"` or `"lower"`) request lowercase normalization, or the literal `"title"` can be used to request title case.

Default`None`

Added`>=1.1.1`

## Usage

Instantiate and assign an instance of this class during construction of a new `Document` subclass. Accessing as a class attribute will return a Queryable allowing string filtering operations, and access as an instance attribute will return a `str` (or `unicode` on Python 2) cast value.

## See Also

* [`Binary`](/reference/fields/binary.md)
