# [Usage](../../../usage.md) > [Components and standard attributes](../basics.md) > defaults

---

`defaults` | `->setDefaults([])`

The default values array for the schema. This will set the default values for the schema on components rendering. You can set the values directly on components or provide this array. Accepts nested values, and the array `key` is the component `name`

| Types   | Default |
|---------|---------|
| `array` | `[]`    |

Bulk fallback map for containers (`Form`, `Repeater`, `Modal` with form). Keys are field `name` attributes, values are defaults applied when neither `value` nor field-level `default` is set. When omitted (`[]`) no bulk defaults apply. Supports nested keys for repeaters and groups.
Prefer this over looping `setDefault` when prefilling many fields.

### Example
Blade:
```php
{!! \KFramework\Components\Forms\Form::make()->setDefaults(['country' => 'Italy', 'city' => 'Rome']) !!}
```
Controller:
```php
Form::make()->setSchema([Input::make('country'), Input::make('city')])->setDefaults(['country' => 'Italy']);
```

### Interaction / tips
- Field `value` (../shared_attributes/value.md) > field `default` (../shared_attributes/default.md) > `defaults` entry.
- Sibling map `values` (../shared_attributes/values.md) sets actual values; `defaults` only fallbacks.
- Keys must match `name` (../shared_attributes/name.md); mismatched keys are ignored.

See also: [values](values.md), [value](value.md), [default](default.md), [name](name.md), [basics](../basics.md), [Form](../forms/form.md).