Overview
Learn the basics about Mighty Image
Introduction
Mighty Image performs real-time, on-request transformations based on URL-query parameters you can define.
URL Anatomy
https://media.mightyimage.io/ demo /examples/tree.jpg ?w=600&h=600
___________________________ _________ _______________ ____________
Mighty Image URL Account ID Subfolder Transformation
& Filename parameters
Available parameters
Resizing
Width (w)
You can specify the width using the w
parameter.
Integer Optional
Height (h)
You can specify the height using the h parameter.
Integer Optional
BoxFit (bf)
You can determine how Mighty Image should fit the width and height by providing a boxfit (bf)
Options:cover, contain, fill, inside, outside
Default:cover
Optional
Gravity (g)
You can change how BoxFit behaves by adding a gravity parameter g
Options: top, right top, right, right bottom, bottom, left bottom, left, left top
Optional
Filters
Greyscale (gs)
Change to output image to greyscale by setting gs
to true
Boolean
Default: false
Optional
Sepia (sp)
Change to output image to greyscale by setting sp
to true
Boolean
Default: false
Optional
Format & Quality
Format (f)
The format of the output image can be changed by setting the f
parameter.
This can be useful to use jpeg
or png
source images and convert them to webp
to improve SEO scores.
Options: jpeg, png, webp
Default: Webp
Optional
Quality (q)
Set he quality level of the output image.
Integer 1—100 Default: 100 Optional
Progressive (p)
Set true
to enable progressive interlacing of the image.
Boolean
Default: true
Optional
Cropping
Width (w)
You can specify the width using the w
parameter.
Integer Mandatory
Height (h)
You can specify the height using the parameter.
Integer Mandatory
Crop top (ct)
Specify where the crop needs to start from the top
Integer Mandatory
Crop left (cl)
Specify where the crop needs to start from the left
Integer Mandatory
Smart Auto Cropping
We support smart auto cropping. When enabled, our algorithm wil determine what the best region is to center the crop. This helps you to auto crop on the main subject like faces, objects, .. in your image. When using this mode, Mighty Image will crop and rescale the image to provide the best possible output image given the requested dimensions.
Smartcrop (sc)
Specify wether smart auto cropping should be enabled with sc
Boolean
Default: false
Optional
Width (w)
You can specify the width using the w
parameter.
Integer Mandatory when smart auto cropping is enabled
Height (h)
You can specify the height using the h
parameter.
Integer Mandatory when smart auto cropping is enable
Text Labels
You can add a text label on top of an image.
Text (ltxt)
The text that should be rendered on the image
Free text Optional
Label top (lt)
Specify where the label needs to start from the top of the canvas
Integer
Default: 0
Optional
Label left (ll)
Specify where the label needs to start from the left of the canvas
Integer
Default: 0
Optional
Label color (lc)
Specify which color the text should have
String, hex of a RGBA color without #
Default: ffffffff
Optional
Label width (lw)
Specify the width of the label. This determines the size, and on how many lines the text wil be rendered
Integer Mandatory when a label text is provided
Label height (lh)
Specify the height of the label. This determines the size, and on how many lines the text wil be rendered
Integer Mandatory when a label text is provided
Last updated on October 25, 2022