Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am trying to install WP-CLI on my Mac using the standard installation command (found here: http://wp-cli.org), yet I am receiving the following error message:

#!/usr/bin/env php

Some settings on your machine make Composer unable to work properly. Make sure that you fix the issues listed below and run this script again:

The detect_unicode setting must be disabled. Add the following to the end of your php.ini: detect_unicode = Off

A php.ini file does not exist. You will have to create one. If you can not modify the ini file, you can also run php -d option=value to modify ini values on the fly. You can use '-d' multiple times.

Installing the main WP-CLI package...

Could not open input file: composer.phar

Installing the Boris package...

Could not open input file: composer.phar

WP-CLI files have been succesfully installed.

To test, run:

/Users/[username]/.composer/bin/wp --info

When I run the test it reports no such file or directory.

I have not installed the bundled PHP that ships with OS X, nor am I using any kind of package. I use MAMP for my local development environment, so my php.ini file is located here:


Can anyone please advise on the best way to get around this error message? Thanks.

share|improve this question
When do you get this error? Is this after you've run installer.sh? I can't see a matching error message and the installer is aware of MAMP being installed in /Applications github.com/wp-cli/wp-cli.github.com/blob/master/… –  booyaa May 21 '13 at 8:17
yes, I get this error after running curl http://wp-cli.org/installer.sh | bash. I just updated my original post with the full error message. –  JP Lew May 21 '13 at 12:56
Do any of the Alternative Install Methods work for you? –  Pat J May 21 '13 at 14:22
no, neither of the Alternative Install methods work. In both cases I receive the exact same error message. –  JP Lew May 22 '13 at 2:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.