Support » Plugin: Wordfence Security » [Plugin: Wordfence Security] Activation failed – Can't get an API

  • Resolved cinematic


    When activating the plugin I am getting the message
    Wordfence could not get an API key from the Wordfence scanning servers when it activated. You can try to fix this by going to the Wordfence “options” page and hitting “Save Changes”. This will cause Wordfence to retry fetching an API key for you. If you keep seeing this error it usually means your WordPress server can’t connect to our scanning servers. You can try asking your WordPress host to allow your WordPress server to connect to

    When I hit “save options” I am getting the error message

    Your options have been saved, but we encountered a problem. You left your API key blank, so we tried to get you a free API key from the Wordfence servers. However we encountered a problem fetching the free key: WordFence API error: Your site sent us an invalid Site URL when requesting an API key. We received: ”

    Entering an API key I got from the didn’t help either.

    The site is hosted on a managed server. Any tips are appreciated.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Wordfence



    Please try the following: Scroll to the bottom of the Wordfence “options” page. Check the box to remove Wordfence data on deactivation. Deactivate and reactivate. Then try your scan again and let me know if it works.



    thanks for your reply. Unfortunately the suggested solution didn’t help. When I check the box to remove Wordfence data on deactivation and click on save I am getting the same error message “Your options have been saved but encountered a problem …”

    When I then deactivate the plugin and reactivate it again the same problem again …

    Hmm. How is this “resolved”? I’m having the same problem. Is mine resolved, too? Gotta tell you. I’m a premium subscriber to Wordfence, and it has the potential to be a good tool, but I’ve never run a successful scan on any of my sites.

    For the record, I have the same error message as above, have followed the author’s suggestion, with the same result as cinematic.

    Hi Davidsdesk, when I got the notification about a new post in this thread and read your message I thought I would give it another try and guess what … NOW it is suddenly working and there is an API key. I have no idea what was causing the problem and why it is working now. I didn’t change much since my last try except updating wordpress and updating the wordfence plugin to the most recent version. Don’t give up, good luck!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: Wordfence Security] Activation failed – Can't get an API’ is closed to new replies.