# Playlists

Playlists are the minimal playing unit in Castmill. For any content that you want to display, you need to use a playlist. A playlist can be as simple as just one media item, or as complex as a layout with several sections with many items per section.

{% hint style="info" %}
Remember that playlists needs to be programmed in a Calendar so that the player knows when to play them.
{% endhint %}

![](https://1755730677-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MYzHH-6laXHQorG99mv%2F-M_UpwhYVUFsdYM6U7w5%2F-M_Uq-MGVXwdrxGAr7eQ%2Fimage.png?alt=media\&token=429e4df5-f73d-4afa-8fb7-abe33203f21a)

You create new playlists by clickin on the "New Playlist" button. A dialog will popup and you will be allowed to choose the layout for your playlist. You can read more about layouts [here](https://docs.castmill.com/content/playlists/layouts).

![](https://1755730677-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MYzHH-6laXHQorG99mv%2F-M_UpwhYVUFsdYM6U7w5%2F-M_Uq7WeII6xOb7lZ2GA%2Fimage.png?alt=media\&token=a321d58b-ce74-43f8-93c4-597b9481cdcc)

For a simple layout such as landscape or portrait, the playlist will have just 1 section. So you can just drag and drop your medias from the Object selection component and rearrange them as you need.

#### Duration

When a media object is added to a Playlist, it gets a duration that depends on the kind of object it is. If it is a video it will be the video's duration, if it is an image or a widget it will have 30 seconds duration by default. However you can easily change the duration of the item by clicking on the duration and sliding the time:

![](https://1755730677-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MYzHH-6laXHQorG99mv%2F-M_UpwhYVUFsdYM6U7w5%2F-M_VPYvzJiUAbyJRVZaw%2Fimage.png?alt=media\&token=c338f318-1fbe-4f70-bef2-4562c11b9d36)

#### Rearrange items

Once the items are in the playlist you can still rearrange them in a different order by just dragging and dropping the items inside the playlist:

![](https://1755730677-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MYzHH-6laXHQorG99mv%2F-M_UpwhYVUFsdYM6U7w5%2F-M_VR9YDcwiTGMcaruiB%2FScreen-Recording-2021-05-12-at-13.54.54.gif?alt=media\&token=f605031b-eba9-41c8-9a1b-500dd472e836)

#### Preview

You can always preview the playlist by using the playlist controls which are similar to a video player. If you want to move the time to a given playlist item just click on the item and the player will move the time to the start of that given item.

####
