01 / PNG
Frames in a grid
Every frame at the same size, left to right and top to bottom, with see-through gaps or a colour key.
Free tool
Drop a GIF, an animated WebP or PNG, or a folder of frames, and get every frame laid out in a grid on one PNG. Choose a grid, one row or one column, the frames to use, the padding, the scale and whether to keep every frame. You also get a JSON file with each frame's position and time, in the hash or array layout game engines like Phaser read, and a CSS animation that plays the sheet on a web page with each frame's own timing. Save all three in one ZIP.
Need a custom tool, app or website? Contact us →Playback
Settings are kept in this browser for next time.
Frames are read and the sheet is made in your browser. Nothing is uploaded.
What you get
01 / PNG
Every frame at the same size, left to right and top to bottom, with see-through gaps or a colour key.
02 / JSON
Position, size and time for each frame, in the hash layout that Phaser and many other engines load.
03 / CSS
A ready animation with steps(), so the sheet plays as a moving picture on a website with no script.
Guide
A GIF to sprite sheet converter takes every frame of an animation and lays them out in a grid on one PNG picture. A game or a web page then loads that single picture and shows one cell at a time, which plays the animation. This tool also writes a JSON file with each frame's position, size and time, and a CSS animation that plays the sheet on a website without any script.
Frames fill the grid left to right, then top to bottom. The padding goes between the frames and around the outside edge too. So the sheet width is the columns times the frame width, plus the padding once more than the number of columns. The height works the same way with rows.
Take a GIF of 24 frames, each 64 by 64 pixels. The tool starts at 5 columns, because 5 is the square root of 24 rounded up. That needs 5 rows, so the sheet is 320 by 320 with one empty cell at the end. Set 6 columns instead and you get 4 full rows, a sheet of 384 by 256 with no gaps. Add 2 pixels of padding to that and the width becomes 6 times 64 plus 7 times 2, which is 398, and the height 4 times 64 plus 5 times 2, which is 266.
| Columns | Rows | Padding | Sheet size | Empty cells |
|---|---|---|---|---|
| 5 | 5 | 0 | 320 by 320 | 1 |
| 6 | 4 | 0 | 384 by 256 | 0 |
| 6 | 4 | 2 | 398 by 266 | 0 |
| 24 | 1 | 0 | 1536 by 64 | 0 |
To find one frame by hand, its left edge is the padding plus its column times the frame width plus padding. In the 6 column sheet with 2 pixels of padding, the 10th frame sits in column 3 and row 1, counting from 0. That puts it at 2 plus 3 times 66, which is 200, and 2 plus 1 times 66, which is 68. The JSON file lists these numbers for every frame so you do not have to.
The page warns you when the sheet is wider or taller than 4096 pixels, because some game engines and phones refuse textures that big. More rows, a smaller scale or fewer frames bring it back under.
The JSON starts in the hash layout: each frame has a name made from your file name, such as run-000 for run.gif, a frame box with x, y, w and h, and a duration in milliseconds. The array layout holds the same boxes as a list, each with a filename, which is what some loaders expect. In Phaser 3 you can load the PNG and JSON together as an atlas in either layout. Engines that cut a sheet by a fixed grid instead want the frame width, frame height, and the padding as both margin and spacing, and Grid sizes only gives just those numbers with the frame times.
The CSS sets a box the size of one frame and moves the background from cell to cell. With one row and no padding it uses a single steps() slide, which gives every frame the same time. Otherwise it lists a keyframe for each frame, placed by that frame's own time, so a GIF with uneven frame times keeps its rhythm on the page. Save the PNG with the name in the CSS, or change the url() to match.
Need frames from a clip first? Use extract frames from video. To save the frames of a GIF as separate pictures instead of one sheet, try GIF to PNG.
Questions
One picture holding every frame of an animation in a grid. Games and websites load it once and show one frame at a time, which is faster than many separate pictures.
A square-ish grid keeps the sheet small. Many engines prefer sheets no wider or taller than 4096 pixels, and the page warns you past that.
Yes. Choose or drop several PNGs at once; they are sorted by name, so frame-1, frame-2 and frame-10 land in order.
Yes. See-through parts of the GIF or PNG stay see-through in the sheet.
No. Everything happens in your browser.
Yes, when the sheet has padding or more than one row: each keyframe starts at its frame's own time. A single row with no padding uses one steps() slide, which gives every frame the same time. The JSON always keeps each frame's own duration.
Yes. Set From frame and To frame, and only those frames go in the sheet, the JSON and the CSS.
It adds empty pixels between the frames and around the sheet. That stops a sliver of one frame bleeding into the next when an engine scales the picture.
100 milliseconds each, which is 10 frames a second. Change the durations in the JSON, or the time in the CSS, if you want a different pace.
Every cell takes the size of the largest frame, and smaller frames are centred inside their cell, so the animation does not jump around.
Yes. Under JSON format, Hash and Array are frame lists for tools such as Phaser, PixiJS and TexturePacker. Grid sizes only gives the frame width and height, margin, spacing and each frame's time, for any engine that slices a sheet by a fixed frame size.
There is no box for an exact sheet size. The size comes from the frame size, Columns, Scale (25%, 50%, 100%, 200% or 400%) and Padding, and the page shows the sheet size in pixels, so try other columns and scales until it fits.
A browser cannot draw a picture wider or taller than 16,384 pixels, so a row of 300 frames cannot be saved as one line. The sheet is wrapped into as many rows as it needs, and the JSON and the CSS list the real place of every frame. If the sheet would still be too big, the tool says so and turns the downloads off until you lower the scale or keep fewer frames.
Yes. When every frame has the same time the CSS uses a simple steps animation. When the times differ, it writes one keyframe per frame at the right percentage, so a slow frame stays on screen longer.