In HTML emails, always set text and background colors in pair
kuon.ch
kuon.ch
I had this issue when I was working on a embed project (similar to embed.ly), some websites had transparent image (in open graph or schema.org) and not all of them were expecting white background, so I have to crawl the page and try to detect the background color best suited for the image. This didn't work well (and required crawling the page) so I ended up doing edge detection on the image (easy with transparency) and average the resulting color to find the best background.