DISCLAIMER: I am not a lawyer. Seek out a lawyer for advice on any of the below. KD Did It assumes no responsibility or liability for any errors or omissions in the content of this site. The information contained in this site is provided on an “as is” basis with no guarantees of completeness, accuracy, usefulness or timeliness . . .
Images are essential on a web page, from the graphics that make up the components of your page (hero, backgrounds, etc.) to the PR photos, product, ads, tables, charts, etc. Think about how boring a website would be without pictures!
Critical Considerations for Images
There are three points to bear in mind when using images for your website:
- They must be relevant to your post or brand
- They must be of the best quality possible
- They must be legally available to you to use
So, images. They add interest to text and illustrate concepts. Popular locations for images are at the top of a web page, image galleries, product photos, and to illustrate points made in text. I use images in my Word Confusions to visually define words.
Basic Code for an Image
Types of Images
There are several types of imagery you can use:
- Stock Photos – pictures you can buy or that the creators share under a Creative Commons-type of license (see (Mostly) Free Image Sources for Your Website at the bottom of this post)
- Those “free” images offered up by sites such as WIX or Adobe for you to use are only free for as long as you’re subscribing to their site.
- Custom Photos – pictures you take or pay someone to take for you (see Tools to Use with Images at the bottom of this post)
- User-generated content (UGC) – images and/or video of your products or services that’s shared or published by customers
- Infographics – combines graphics and text to deliver a lot of information
- Video – great for tutorials or to deliver a more complex message than a single image can do
- Animation – ranges from an animated hero banner, navigation bar, dynamic background, creative motion and transition effects, etc.
Basic Image Rules
- Keep the original (BIG) images, preferably at 300ppi, in an originals folder
- Make a copy of the original image, rename it for how you plan to use it — always work with a copy of the original image!
- For use on the Internet, save your image files at 72ppi (pixels per inch)
- You never want to make an image bigger as its quality downgrades, always use that original huge image to downsize
- If your program gives you a choice of color modes, save the file as RGB (for Internet; CMYK is a print mode)
- Make your images responsive to the size of the screen
- Define dimensions – width x height
- Record the actual width x height, but
- Use percentages in the CSS/HTML, so the size of the image will respond to the size of the screen — width:100%
- Use image size optimization – balances quality with compressing the file size thereby reducing the size of the file
- While size, W x H in pixels (ppi), is important, it’s equally important that you pay attention to ratios — it’s all about proportions and how the viewer’s screen may alter the size
- Verify that you can legally use the image
- Give credit to the original source of your image
- Consider search engine optimization (SEOs) for your image — the process of improving the quality and quantity of website traffic to a website or a web page from search engines
- Use a unique image, if you can
- Use an
alt
andtitle
tag - Include a caption, if the visual is of great importance to the content of the page, although the
title
can act as a caption - Give the image a name you’ll recognize (and can find) — it’s also easier for search engines to find! “5JkO795_img_XRK” doesn’t tell the search engine a dang thing!
- I had started naming my word confusion post images according to what was in the photo. I quickly realized that was stupid. Now I name the file for the word it’s visually defining, which also makes that filename a keyword.
- I save these in an ORIGINALS folder on my computer, so I always have the original (as a PSD file). Then open up the image and save it under a new name in your IMAGES folder (“Originals” is a subfolder within “Images”) to compress it. This way, if you screw something up, you have the original to go back to.
- Have a signed model release form for each identifiable person in a photo
- Image sitemaps help Google better index the images and improves the user experience and loading time of your website (Optimizing) — image sitemaps are most useful for image-heavy sites, e.g., stores, photographers, other artists, etc.
File Formats for the Web
You do want the best quality images possible. As I mentioned earlier, keep original images in a separate file within your IMAGES folder that way you can always go back to it if you don’t like the changes.
In general, the Internet accepts .webp, .jpg, .jpeg, .png, .bmp, and .svg. (A .psd file is a Photoshop file extension that allows you to keep layers separate.)
WebP (pronounced “weppy”) is very good and gaining popularity for a number of reasons — it combines several file formats, GIF’s motion, and PNG’s transparency. It compresses better without quality loss, keeping solid resolution — as long as you save it as a lossy as the lossless choice is actually bigger than my JPGs. (I’ve also found that sometimes my JPGs are smaller than my WebPs, and sometimes vice versa.) It’s recommended by Google (with major browsers adopting its support), and it will boost your SEO. The negative is that some site builders and apps may restrict you from uploading WebP files. WordPress has allowed .webp since version 5.8 — and doesn’t require a plugin. You can save .webp in Photoshop, but it’s a pain without the plugin.
JPEG (also JPG) (Joint Photographic Experts Group) is the most popular, primarily because it compresses to a smaller size than a PNG. While it’s great for color photography, products, blog, and background images, you’re better off waiting to save it as a JPEG file until the very end, as the file degrades with each save.
sRGB is a standard RGB (red, green, blue) color space for photography. Its color reproduction is stable across the Internet and minimizes the chances of unexpected color shifts. Wider color spaces are available in Adobe RGB or ProPhoto RGB. “When exporting images for the internet or printing photos, it is essential to save them in the sRGB color space. Many image editing software, like Adobe Lightroom, allow users to convert images to sRGB before exporting, ensuring that the final JPEG is saved in sRGB. This helps guarantee that colors appear as intended, both online and in print.” Do NOT convert sRGB to Adobe RGB.
BMP (Bitmap) is an uncompressed raster graphics file format, which makes them ideal for displaying and storing high-quality images. Makes detailed images with crisp edges and no artifacts, which also means larger file sizes. You can convert a BMP to a PDF, which will reduce file size without reducing quality.
PNG (Portable Network Graphics) is great if you have any transparent areas in your image as well as icons, logos, and other graphics such as screenshots and other types of imagery where there’s not a lot of color data. It also maintains its quality. It does make for a bigger file size than a JPEG, which can slow download times.
GIF (Graphics Interchange Format) are best for animations. Do not use for static images as their file size is always larger even if it’s not an animation.
SVG (Scalable Vector Graphics) use mathematical formulas that stay crisp and clear regardless of any size changes or the device used to view them. They’re great for text and web graphics like logos, illustrations and charts. Screen readers can scan any words contained in SVG images. The most common vector formats are .eps, .ai, .svg, and .pdf. The browsers that support SVG include Safari, Opera, Firefox, Chrome, Samsung, Internet, Microsoft Edge, Android browser, Internet Explorer, and Baidu Browser.
Image Sizing
Bigger sizes slow the download speed which can drastically affect your SEO rating (save big files in your originals folder), so you’ll want to optimize your image file.
- Mention is made of a
loading
attribute with alazy
value which would allow larger files — and it requires knowledge of and access to JavaScript OR you can use a plugin
Image Optimization
Use optimization — a method of compressing the image that balances image quality with a smaller size — to decrease the file size of your image while maintaining quality. You’ll need to get the plugin, as these sites send your compressed images to your Media Library.
A number of sites recommended TinyJPG for compressing WebP, JPG, and PNG images. Also check out Imagify free for up to 200 images per month with a maximum upload size of 2MB per image. TinyIMG converts JPEG and PNG to WebP and vice versa, starting at $14 per month.
Smush has a free and a paid plan. Optimus compresses your images when they’re uploaded to your WordPress Media Library. There is a free and two paid versions; only the paid versions allow this automation on an https:// site and conversion for WebP images. Optimus HQ Pro allows you to use it on multiple sites. Now, EWWW Image Optimizer also automatically optimizes images when uploaded AND it can optimize previously uploaded JPG images. Nor do you have to worry about file sizes, as EWWW takes ’em all. To compress PNG, GIF, and WebP, you’ll need the paid version. WP Compress is great if you’re managing multiple client sites.
Most of these aforementioned plugins have a free level as well as paid plans. Some only charge if you exceed the maximum allowed number of images per month. Each has different limits on the file size they’ll compress.
-
Fig. 1. Breakdown on Image Size Saving courtesy of TinyJPG
Ratios versus Pixels
Ratios are about proportions. It uses W x H, but only to ensure that the width and the height are proportionate to the required aspect ratio. For instance, a 16:9 ratio can be 2400 x 1600px. or 400 x 150px while a 1:1 ratio could be 150 x 150px or 1243 x 1243px.
Where a ratio is essential is in your web page parts as well as social media site parts, those profile pictures, banners, covers, book covers, thumbnails, etc.
Ratios truly are critical. If you use the ratio recommended for the different images you can use on an individual site, your image won’t be cropped, become pixelated, appear stretched out, etc.
I’m horrible at math, so I use a ratio calculator to figure out the height.
The image shape, using ratios, for each section of your site includes:
Shape | Common Ratios | Size | Commonly Used |
---|---|---|---|
Panoramic | 16:9 * | 1920 x 1080px | Hero image for standard widescreen sizes and used in presentations, widescreen TVs, and landscape images |
Landscape | 1.59:1 | Minimum of a 1080px width | Different social media platforms, featured images for blog posts and other content |
Rectangle | 3:2 * | 1080 x 720px | In print or on phones |
4:3 | 640 x 480px | Smaller screen sizes or placements | |
4:3 | 2048 x 1536px | Full-screen takeovers | |
Square | 1:1 ** | 1080 x 1080px is most common | Great for in-text images, sidebar ads, Instagram, favicons |
Mobile responsiveness means the image is automatically resized, but not necessarily the way you’d want:
* This size of image will be cropped, so keep the focus area of the subject in the middle ** An image with a 1:1 ratio will display just fine |
Do remember that just because that a ratio is 16:9 doesn’t mean that it has to be 1920 x 1080px. It could just as easily be 400 x 225px. Just as a 1:1 ratio can be any size square, as long as the width and height are the same. It’s all about the proportion!
I recommend creating templates in the ratio/wXh sizes you’ll need, then you can re-size your image to fit those templates — and re-name the template to reflect what that particular image is for, e.g., bkCvrThbNl-500.jpg
which would translate (for me!) to a book cover thumbnail for the book title that includes “500” OR prPhoto105x128.png
translates to a PR photo that is 105 x 128px.
Make Your Images Responsive
Users are used to scrolling websites vertically on both desktop and mobile devices — but not horizontally! If the user is forced to scroll horizontally, or zoom out, to see the whole web page, it results in a poor user experience.
Use CSS/HTML to make those images responsive:
- Use relative width values, such as width: 100%.
- Try to avoid using large absolute positioning values (you tell it exactly where you want the image to be on the screen). It may cause the element to fall outside the viewport on small devices.
For a responsive website, you want your site to automatically resize your images, a.k.a. fluid images, to create a good user experience. Set yourself up for success with the following:
The head tag: |
Insert <meta name=”viewport” content=”width=device-width, initial-scale=1.0“> between the <head> tags. (See the note on adding meta tags at the bottom of the page.) |
Set up a CSS class for a responsive image: |
Ensures the image will fit any size screen: .responsive { width: 100%; height: auto; } |
The image code: |
In the web page, the HTML would appear as: <img src=”https://kddidit.com/images/blogPosts/exceed.png” alt=”Two overflowing trashcans in the middle of a park” class=”responsive” width=”600” height=”400” title=”I’d say the amount of garbage exceeds the cans’ capacity.“> |
Image looks like: |
Save Yourself Legal Grief
Images are amazing and bring so much life to your website . . . and the most important thing you can do is ensure that you have permission to use it. Bookmark the post “Understanding Licensing” for a shot at saving yourself grief.
I cannot emphasize this enough. You must ensure that the image you want to use is:
- Available for your use — read the terms of its copyright license (“Understanding Licensing” will open your eyes to the variety of restrictions that exist on the use of images)
- Try to avoid using images with faces a person would recognize UNLESS you get a model release form signed by the person(s) in the photo.
- People in the public eye don’t have that protection, ALTHOUGH, you CANNOT:
- Use their image to mislead or deceive your customers
- Make a false or misleading representation that goods or services have sponsorship, approval, performance characteristics, accessories, uses, or benefits
- People in the public eye don’t have that protection, ALTHOUGH, you CANNOT:
- Don’t use images from social media such as Instagram, TikTok, Pinterest, etc., without getting permission from the poster
- Some photos may be for “editorial use only” — in these instances, you can use the photo for a publication like a newsletter or a blog, but you can’t use the photo for a Facebook ad or a corporate home page
- A photo taken by yourself for your own use is good — a photo taken for a company or a client is NOT yours
- Get permission to use any GIFs
Information on United States copyright fair use law is available from the United States Copyright Office.
I know, the temptation to use a particular image can be overwhelming . . . so can that fine be overwhelming. Keep looking. Note that there is an upcoming post on Getting, Tracking, and Noting Permissions.
Include Credit for the Image
Always include credit for the image. At the very least, credit the creator of the image and the license it’s under. Include links wherever possible. It’s a great way to thank the creators for allowing us to use their images. Creators like illustrators, graphic artists, and photographers make their living from the images they create. Bringing traffic back to their sites ensures they have the opportunity for more people to see their work and potentially profit from being hired to create more work or sell a piece of work they’ve already created.
The ideal is to provide the title of the work, the author/artist/photographer of the work, the licensing information, and the address of the site where you found the work — with links to everything.
The code to give credit: |
<figcaption><span class=”notItalics”>0541 Street Band</span>, New Orleans, by <a href=”https://www.flickr.com/photos/mmorgan8186/5309556635/”>Mark Morgan Trinidad A</a> is under the <a href=”http://creativecommons.org/licenses/by/2.0/”>CC BY 2.0</a> license, via Flickr.</figcaption> |
Looks like: |
|
If you want to contain the caption within the sides of the image, box it up. |
Set up a CSS class to frame the image and contain the caption: |
.figure{ |
The code: |
<figure><img src=”https://kddidit.com/images/blogPosts/timbre.png” alt=”A five-man band in jeans and T-shirts playing on a sidewalk.” title=”I love this colorful image!“> <figcaption><span class=”notItalics”>0541 Street Band</span>, New Orleans, by <a href=”https://www.flickr.com/photos/mmorgan8186/5309556635/”>Mark Morgan Trinidad A</a> is under the <a href=”http://creativecommons.org/licenses/by/2.0/”>CC BY 2.0</a> license, via Flickr.</figcaption> |
Looks like: |
There is a wide range of styles giving credit throughout the Internet. Explore. See what suits your style while providing the minimum. And see image credit in the post on “Hyperlinks and Linking” for help in coding the credit, unless you use something like WordPress’ linking features.
There’s a very thorough section on attributions in the post “Understanding Licensing”.
If you need to “get permission from the image’s creator, ask if they have assigned their rights to someone else or if it was taken as part of their employment duties and they no longer own copyright in the image. Ask for a warranty or guarantee that they’re the image creator, still own the rights in the image, and have the right to provide you with permission to use it” (6 Best). There’s an upcoming post on Getting, Tracking, and Noting Permissions.
Stock photo agencies generally charge for an image, and there may be restrictions on how you can use it or how many times it can be used.
Be wary of images that claim to be royalty-free. It doesn’t necessarily mean they’re free to you.
Ensure that your images are accessible by including an alt
and a title
tag (see image link in the post on “Hyperlinks and Linking” for the coding).
Getting the Image from Your Computer to the Internet
There are several ways to upload your images to your website:
- Go through the cPanel of your web host and upload it in an images file
- Upload it through a site like WordPress to its Media Library
- Use an FTP program to upload it
- Image hosting services – there can be an annual fee, but you can upload some huge files
- Create an account at Flickr, Imgur, Google Drive, or Apple iCloud and upload your image
Whichever way you choose, you’ll need to add the image’s URL to the actual page on which you want it to appear.
Exploring More . . .
You may want to also look at more possibilities in “First Steps for a Website“, “Outline Your Website“, “Anatomy of a Web Page“, “Hyperlinks and Linking“, “Pages on the Front End of Your Website“, “Pages Behind the Scenes of Your Website“, “More Specific Disclosures for Your Website“, and “Navigation For Your Website“.
You may want to also look at more possibilities for fun on the homepage Building Your Author Website“. The posts on “Understanding Licensing” and “Inserting Diacritics” may be useful as well.
Building Your Author Website is . . .
. . . an opportunity to do a bit more with your author’s website or blog and have some fun with it as well as getting a look at building it from the ground up with a comprehensive listing of the pages you’ll need . . . all while learning something about HTML (hypertext markup language) and CSS (cascading style sheets) — the easy way, lol.
If you found this post on “Images on Your Website” interesting, consider subscribing to KD Did It, if you’d like to track this post for future updates.
Images on Your Website | ||||||
Part of Web Building: Graphics | ||||||
Definition: Representation of a drawing, photograph, lettering, illustration, map, table, infographic, graphics, chart, video, audio, anything that’s not text.
Keep in mind the feel and colors of your brand — each choice will reflect on you and your website’s purpose.
|
||||||
Website Parts Behind-the-Scenes | ||||||
Definition: The following are about the images that make up the anatomy, what’s “behind-the-scenes”, of your site’s content. | ||||||
Background | Definition: Think of it as the blank page on which you’ll place everything — text and images. | |||||
Return to top or post contents |
Your background is actually composed of two parts: the actual page and the background background.
The backmost background can be a solid color, a print background, an image, animation, or a video. The page background is a different animal that sits on top of the background and is best as a solid color that contrasts well with any text — white is a classic. Consider your brand — your style and website template capabilities — when deciding on background. The best background for a website depends on its purpose and content. Be sure that your content can be easily read — use an accessible color generator to help determine the best contrasts. Ideally there will be high contrast between it and any text. Format sizes range from:
|