Enabling the extension in php.ini
To allow PHP to load the extension, you have to add it to php.ini found in your PHP directory. It will not be there by default.
First search for Dynamic Extensions. You will notice a bunch of extension=abcdef entries. The semicolon (;) means that extension is disabled.
Somewhere in that list of extensions, add extension=imagick. I like to add it close to the end or next to gd.
Finally, save and close php.ini.
Adding Imagick to the Path environment variable
Unlike the PHP step which is optional, this step is not optional. In order for the Imagick extension to work, Windows has to find its location through the Path environment variable.
In the Start menu, search for environment variables and open Edit the system environment variables.
Then click the Environment Variables… button in the System Properties window.
Under System variables, look for the Path variable, then click the Edit… button.
On the new screen, click New and type C:\php\extras\imagick (or the path you chose to extract the Imagick extension on the web server), then click OK to close this window.
Click the OK button two more times and you are all set.