imgix APIs
Rendering API
Frame Interval

Frame Interval


Premium Feature

Frame Interval functionality is currently available for imgix customers on our Premium plans. If you’re interested in this feature, please contact our sales team (opens in a new tab) to get more information on this feature.

Displays every Nth frame starting with the first frame. The value must be an integer greater than 0 and smaller than the total number of frames.

Given an input N, interval keeps every Nth frame. The frame numbers are displayed in the examples below to make the missing frames more clear.

This parameter is useful for previewing longer GIF images by only showing a subset of frames. By combining it with fps, you can generate a preview to a preset duration:

interval = total_frames / ( fps × duration )

The total number of frames, if not known, can be determined by applying fm=json to the animated GIF to extract its "Frames" metadata:

  "GIF": {
    "DelayTime": 0.1,
    "UnclampedDelayTime": 0.04
  "Content-Type": "image/gif",
  "Output": {
    "Frames": 199
  "ColorModel": "RGB",
  "Content-Length": "7313455",
  "Depth": 8,
  "PixelHeight": 169,
  "PixelWidth": 300,
  "ProfileName": "sRGB IEC61966-2.1"