Create thumbnail size in WordPress

In WordPress we can add our very own thumbnail size we want so we can use in our customization.

Add this code in your favorite functions.php.

Using add_image_size function of WordPress. In my case I create a 285×148 size of thumbnail. The first option is the name of image that you can use to call your image size whenever you need it.

Also to make this effect, we need to regenerate or refresh our upload images. To do that google or find in WordPress respository the plugin called regenerate thumbnail.