• Resolved led500

    (@led500)


    When I go to SG optimizer it displays this error and I cannot enable or change anything:

    COULD NOT CONNECT TO THE WORDPRESS REST API
    Either a security plugin, custom function or rules in your .htaccess file is preventing the WordPress REST API from working properly. SG Optimizer is using it to store its options and other functionalities so please make sure it works properly.

Viewing 15 replies - 1 through 15 (of 19 total)
  • Plugin Author Stoyan Georgiev

    (@stoyangeorgiev)

    Hello there,

    There is a high probability that a security plugin is blocking the access to the plugin. This may also be caused by a custom function or a htaccess rule.

    You can try to disable any security plugins and see if the notice is still present. Keep in mind that rules written the htaccess remain there after a security plugin is disabled.

    You can also check your console for any errors that could indicate the exact reason for the API to not function properly.

    If you have more questions, don’t hesitate to reach back at us!

    Regards,
    Stoyan

    Thread Starter led500

    (@led500)

    I was able to solve this. It was wordfence firewall blocking for Improper REST capabilities checks.

    Thank you!

    Plugin Author Hristo Pandjarov

    (@hristo-sg)

    SiteGround Representative

    Glad you had it working ??

    @led500
    how did you fix it without disabling Wordfence ?

    @svenms Go to Wordfence > Tools and check the Live Traffic logs. It should be reporting the sg-cachepress connection as a 403 error – click on one of those and hit the “whitelist this param from firewall” button and you should be good to go.

    @spoonofmilk Thanks!

    I also resolved the problem by disabling a plugin named “WPFront Notification Bar” that caused conflicts.

    klishb

    (@klishb)

    I’m seeing the same problem with “WPFront Notification Bar”. I really like that plugin. I’m going to open a support thread with them.

    I have the same problem, however the ONLY plugin i have installed is the sg siteoptimizer.
    No other plugins, or had. But I DO have this error.
    I also didnt rewrite any rules in php or whatsoever…

    Someone can help? thnx

    I just fixed the same issue, primary site on a multisite, url was naked but for some reason was showing www in the options table, edited the db and magically started working.

    Same trouble, hosted in Siteground, plugin cannot contact with REST API

    Htacces very clean

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    ?What we can do?

    Thanks for your support

    Same issue here, completely clean installation, using SiteGround’s own WordPress Kit.

    for anyone getting this issue on a fresh install, if you are using Cloudflare for your DNS ensure you have the “proxy” option set to Off/dns only . and also in the SSL tab in cloudflare make sure it’s set to full and not flexible.

    I’ve had this problem for over a month, I’ve already uninstalled all plugins, cleaned htacess and I still couldn’t solve it…

    This started after I turned cloudflare on and off by mistake…
    Can anyone help me?

    Plugin Author Stanimir Stoyanov

    (@sstoqnov)

    SiteGround Representative

    Hey @caaslu

    Please open a new thread and provide your site URL, so we can check the issue.

    Regards,
    Stanimir

    I have been going back and forth with my hosting company about these ( Site Health } checking issues that have been coming up out of the blue. I can really use some help, please.. It’s making me nuts trying to solve this issue. My hosting company said its a plugin issue. I turned off all the plugins one at a time running tests but the issue remains. I am concerned. It says my website has been disabled but that is not true. I am still able to pull it up..
    The REST API is one way WordPress, and other applications, communicate with the server. One example is the block editor screen, which relies on this to display, and save, your posts and pages.

    The REST API call gave the following unexpected result: (403) This website has been disabled. If you are the site owner, please contact Technical Support for further information and assistance.

Viewing 15 replies - 1 through 15 (of 19 total)
  • The topic ‘COULD NOT CONNECT TO THE WORDPRESS REST API’ is closed to new replies.