Docs | imagemash.io
DashboardSign up for Free
  • 🎉imagemash.io
  • 🚀Getting Started
    • Simple CDN Link Usage
  • 💽Sources
    • IM Cloud Storage
    • Image URL
    • Storage Providers
      • Amazon S3
      • Google Cloud
      • S3 Compatible Storage
    • Web Folder
  • 🖼️Image Transform
    • Transform Options
      • Quality
      • Width
      • Height
      • Scale
      • Crop
      • Gravity
      • Background
      • Border
      • Round
      • Output Format
      • Angle (Rotate)
      • Flip
      • Helpers
        • x, y
      • Filters
        • Tint
        • Flatten
        • Grayscale
        • Blur
        • Sharpen
        • Median
        • Threshold
        • Negative
    • Transform Cheat Sheet
    • Named Transforms
  • 🛠️API
    • API - Good to knows
    • API Methods
      • Account
        • Named Transforms
          • Get named transforms
          • Add named transform
          • Remove named transform
        • Image URL Restriction
          • Get keyword list
          • Add keyword to list
          • Remove keyword from list
          • Change keyword list usage
      • Storage
        • Upload file
        • Get and search files
        • Delete files
        • Add new tags to files
        • Set tags of files
        • Remove tags from files
        • Purge Cache
      • Optimize / Transform
  • ❓How it works?
    • Custom Domain
    • Bandwidth
    • Cloud Storage
    • Caching
    • Purge Cache
    • Limits
  • Contact Us
Powered by GitBook
On this page
  1. Image Transform
  2. Transform Options

Background

background - bg - bg_<color value>

PreviousGravityNextBorder

Last updated 2 years ago

Value
Type
Description

color value

string, hex

Default Value: white

Value can be;

  • 3-8 Digit RGB or RGBA Hex (without #)

  • A named color

Eg. bg_orange, bg_FFF, bg_C40087

Changes the background color of an image if there is any space left after cropping.

To see all named colors:

This function does not change the default background of an image.

Auto

Auto property calculates the proper background color for your image's theme

🖼️
https://drafts.csswg.org/css-color/#named-colors
https://demo.imagemash.io/w_500,h_200,c_contain,bg_palegreen/eg1.png
https://demo.imagemash.io/w_500,h_200,c_contain,bg_auto/eg1.png