---
title: "Statamic"
description: "Statamic is a Laravel-based CMS built by the team at Statamic, LLC, in the USA."
canonical_url: "https://codex.republic.se/cms/statamic"
section: "Pages"
---

# Statamic

*Statamic* is a Laravel-based CMS built by the team at Statamic, LLC, in the USA.

## Project setup

### Set up a project locally

Since *Statamic* doesn’t have a database, it’s less complicated than *Craft* to get going.

1. Clone the repo from *GitHub*.
2. Start *DDEV*.
3. Create a **.env** file and copy the content from *1Password*.

### The Control Panel

The admin is called the *Control Panel* (CP) in *Statamic* and can be reached via **https://statamic.test/cp/**

### Templates

*Statamic* uses its own templating engine called [***Antlers***](https://statamic.dev/antlers). Probably named after the fact that the **{{** used as delimiter looks like antlers.

Antlers used to be more like the template language used in *ExpressionEngine* back in the day, but has matured considerably lately and includes both variables and logic today, just like *Twig*.

- Templates are located in **/resources/views/**
- [Index over tags used in *Antlers*](https://statamic.dev/tags)
- [The official guide to how to write Antlers syntax (Style Guide)](https://statamic.dev/antlers)

### Fields

Just like in *Craft*, you can create your [***Fields***](https://statamic.dev/fields) in the CP.

But, since no databases are involved, you can copy the text files with the config left and right if you like. These are located in **/resources/fieldsets/**.

A collection of fields can be saved as a [***Fieldset***](https://statamic.dev/fieldsets).

Everything is saved in [YAML-format](https://statamic.dev/yaml) and looks something like this:

```
title: Header
fields:
  -
    handle: headerbox_bg
    field:
      options:
        color: 'Enfärgad bakgrund'
        image: Bild
        video: Video
      multiple: false
      max_items: 1
      clearable: false
      searchable: true
      taggable: false
      push_tags: false
      cast_booleans: false
      display: 'Bakgrund för headerbox'
      type: select
      icon: select
      listable: hidden
  ...

```

**YAML is based on indentation**, so it’s very important that the data is indented in the right way.

Statamic has many built-in [***Fieldtypes***](https://statamic.dev/fieldtypes):

- [Array](https://statamic.dev/fieldtypes/array) | Manage data in a key:value array format.
- [Assets](https://statamic.dev/fieldtypes/assets) | Upload files and use the Asset Browser to pick from existing files in your Asset Containers.
- [Bard](https://statamic.dev/fieldtypes/bard) | Rich article writing and block-based layouts made easy.
- [Button Group](https://statamic.dev/fieldtypes/button_group) | Buttons you click. You can only choose one.
- [Checkboxes](https://statamic.dev/fieldtypes/checkboxes) | Boxes you check. You can check 'em all.
- [Code](https://statamic.dev/fieldtypes/code) | Write code and see it highlight. But will you choose spaces or tabs?
- [Color](https://statamic.dev/fieldtypes/color) | Pick colors, enter hex or HSLA values, and other colorful things.
- [Date](https://statamic.dev/fieldtypes/date) | Helps you pick a date, but not get one.
- [Entries](https://statamic.dev/fieldtypes/entries) | Create relationships with other entries.
- [Hidden](https://statamic.dev/fieldtypes/hidden) | Set default data when creating new entries.
- [Integer](https://statamic.dev/fieldtypes/integer) | For when all you want is numbers.
- [List](https://statamic.dev/fieldtypes/list) | Manage simple lists with the help of a keyboard-friendly interface.
- [Markdown](https://statamic.dev/fieldtypes/markdown) | Our beautiful Markdown editor with preview, assets integration, and more.
- [Radio](https://statamic.dev/fieldtypes/radio) | Circles you click. You can only choose one.
- [Range](https://statamic.dev/fieldtypes/range) | Choose a number between a min and max value.
- [Revealer](https://statamic.dev/fieldtypes/revealer) | A button that reveals conditional fields like magic.
- [Section](https://statamic.dev/fieldtypes/section) | A visual header to help break up and organize long publish forms.
- [Select](https://statamic.dev/fieldtypes/select) | Choose from predefined options. This field is highly configurable.
- [Table](https://statamic.dev/fieldtypes/table) | Create and manage simple tables of limitless columns and rows.
- [Tags](https://statamic.dev/fieldtypes/tags) | Enter a list of items with a tag-style interface.
- [Template](https://statamic.dev/fieldtypes/template) | A template picker with autosuggest.
- [Terms](https://statamic.dev/fieldtypes/terms) | Attach Taxonomy Terms to your content.
- [Text](https://statamic.dev/fieldtypes/text) | A simple text input field for managing short, unformatted text.
- [Textarea](https://statamic.dev/fieldtypes/textarea) | A simple textarea field for managing longer, unformatted text.
- [Time](https://statamic.dev/fieldtypes/time) | A timepicker. It lets you pick a time.
- [Toggle](https://statamic.dev/fieldtypes/toggle) | A toggle switch for booleans (true and false).
- [Users](https://statamic.dev/fieldtypes/users) | Relate users with your content.
- [Video](https://statamic.dev/fieldtypes/video) | Extract embed URLs from Youtube, Vimeo, and HTML5 compatible video links and preview them right inline.
- [YAML](https://statamic.dev/fieldtypes/yaml) | A YAML editor that *directly* manages YAML.

### Content

How to save the data is defined by **Collections**. They are similar to *Sections* in *Craft*. Examples of Collections can be Pages, Products, Persons, etc.

All data is also saved in YAML-files located in **/content/**.

The different types of content include:

- Assets
- Collections
- Globals
- Navigation (special collections for building navigation)
- Taxonomies (tags/categories for labeling data)

### Blueprints – connects fields and content

To decide which fields should be visible for which collection or asset, Statamic uses **[Blueprints](https://statamic.dev/blueprints).** This is where you decide which fields (or fieldsets) should be visible for each type of content.

## Addons

There are many [addons to Statamic](https://statamic.com/addons), but as with Craft CMS, we try to use as few as possible as a general rule.

[Here is a collection of the ones we have used](/cms/statamic/addons) and the ones we’ve been looking at.

## Articles

- [A Beginners Guide to Antlers Arrays and Loops - Stillat](https://stillat.com/blog/2022/11/01/a-beginners-guide-to-antlers-arrays-and-loops)
- [Creating &amp; hosting a static site on Vercel with Statamic](https://www.daronspence.com/2022/11/16/new-blog-creating-and-hosting-a-static-site-on-vercel-with-statamic)
- [How To Optimize Images for Web and Performance](https://www.halo-lab.com/blog/how-to-optimize-images-and-an-example-of-optimization-with-our-plugin-for-11ty)

## Editor plugins

Make the editor your best friend, you’ll be hanging out together for quite some time.

- [Antlers Toolbox for Statamic](https://antlers.dev/)
- [Antlers Language Support - IntelliJ IDEs Plugin](https://plugins.jetbrains.com/plugin/19203-antlers-language-support)

## Starter kits

We have not used these, but there is a way to get a flying start with what’s called ***Starter kits***. These are close to themes in other CMSes and often based around a specific use case such as a blog, a small company website, etc.

- [Peak](https://peak.studio1902.nl/)
- [Landtamic](https://landtamic.com/)
- [Cloud](https://cloud.luckymedia.dev/)

---

- [ Addons ](/cms/statamic/addons)
