# Structure

# dotLottie Structure

dotLottie is an open-source file format that aggregates one or more Lottie files and their associated resources (images, fonts, etc) into a single file to enable efficient and easy distribution of an animation. dotLottie files are ZIP archives compressed with the Deflate compression method and carry the file extension of .lottie.

A dotLottie file ZIP archive has the following file and folder structure:

.
├─ manifest.json
├─ animations
│  ├─ animation-1.json
│  └─ animation-2.json
├─ images
│  ├─ img_1.json
│  └─ img_2.json
├─ themes
|  ├─ theme_1.json
|  └─ theme_2.json
├─ states
│  ├─ statemachine_0.json
│  └─ statemachine_1.json
├─ audio
│  └─ audio.mp3
  • manifest.json — JSON file containing metadata about the animations (version, author details, list of animations in the package, playback configuration, playlist/sequencing information).
  • animations — Folder containing the animation(s).
  • images — Folder containing image assets required by the animation(s).
  • themes — Folder containing different themes for the animation(s).
  • states — Folder containing state machines.
  • audio — Folder containing audio asset required by the animation(s).

# manifest.json

{
  // Name and version of the software that created the dotLottie
  "generator": "LottieFiles 1.0",

  // Target dotLottie version
  "version": 1.0,

  // Revision version number of the dotLottie
  "revision": 1,

  // Name of the author
  "author": "Alibeyya",

  // List of animations
  "animations": [
    {
      // Name of the Lottie animation file without .json
      "id": "test",

      // Desired playback speed
      "speed": 1.0,

      // Theme color
      "themeColor": "#ffcc00",

      // Whether to loop or not
      "loop": true
    },
   // More animation file listings, if any...
   ....
  ],

// Custom data to be made available to the player and animations
  "custom": {},

  // IDs of the state machines
  "states": {},

  // IDs of the themes
  "themes": [
    {
      // Name of the theme file without .json
      "id": "theme1",

      // List of animations scoped to this theme, if any (optional)
      "animations": ["test"],
    }
  ]
}

# Sample dotLottie Files

Simple Animation
animation.lottie
13KB (88%reduced)
Download
Animation with Image asset
animation-external-image.lottie
584KB (16%reduced)
Download
Animation with Image(base64)
animation-inline-image.lottie
835KB (66%reduced)
Download