# 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
├─ fonts
|- js
|- resources
└─ previews
  • 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).
  • fonts — Folder containing font assets required by the animation(s).
  • js — Folder containing Javascript files required for scripting and interactivity.
  • resources — Folder containing miscellaneous assets required and in support of the animations. This may be used to store and distribute original source files for the animation(s).
  • previews — Folder containing preview images for any of the animation(s), named with the base filename the same as the animation file’s base filename.

# 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": {}
}

# 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