Title: Error re JSON / REST API
Last modified: November 10, 2018

---

# Error re JSON / REST API

 *  Resolved [jeffeisenberg](https://wordpress.org/support/users/jeffeisenberg/)
 * (@jeffeisenberg)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/)
 * Hi John. I moved my site to a different host by copying files and database. Everything
   should be the same and everything works fine except for the following error in
   the redirection plugin. Can you give me some direction in how to resolve?
 * Thanks.
 * Plugin: 3.6.2
    WordPress: 4.9.8 (single) PHP: 7.2.11 Browser: Mozilla/5.0 (Windows
   NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77
   Safari/537.36 JavaScript: [https://www.sfveincenter.com/wp-content/plugins/redirection/redirection.js](https://www.sfveincenter.com/wp-content/plugins/redirection/redirection.js)
   REST API: [https://www.sfveincenter.com/wp-admin/admin-ajax.php?action=red_proxy&rest_path=](https://www.sfveincenter.com/wp-admin/admin-ajax.php?action=red_proxy&rest_path=)
 * Error: Unexpected token < in JSON at position 0
    Raw: <!DOCTYPE HTML PUBLIC “-//
   IETF//DTD HTML 2.0//EN”> <html><head> <title>500 Internal Server Error</title
   > </head><body> <h1>Internal Server Error</h1> <p>The server encountered an internal
   error or misconfiguration and was unable to complete your request.</p> <p>Please
   contact the server administrator at [webmaster@sfveincenter.com](https://wordpress.org/support/topic/error-re-json-rest-api/webmaster@sfveincenter.com?output_format=md)
   to inform them of the time this error occurred, and the actions you performed
   just before this error.</p> <p>More information about this error may be available
   in the server error log.</p> <p>Additionally, a 500 Internal Server Error error
   was encountered while trying to use an ErrorDocument to handle the request.</
   p> </body></html>

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [John Godley](https://wordpress.org/support/users/johnny5/)
 * (@johnny5)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-10867205)
 * This kind of thing is usually caused by a security plugin of some kind. Does 
   that match your setup? Have you tried the other options in the REST API dropdown
   in the error?
 *  Thread Starter [jeffeisenberg](https://wordpress.org/support/users/jeffeisenberg/)
 * (@jeffeisenberg)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-10867443)
 * I’m going to close this. I realized this was caused because I had changed my 
   local hosts file to trick my computer to thinking my url resolves to the new 
   host… for testing purposes. When i changed actual public DNS, the error went 
   away.
 * Thanks for the quick response!
 *  Thread Starter [jeffeisenberg](https://wordpress.org/support/users/jeffeisenberg/)
 * (@jeffeisenberg)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-10867646)
 * Sorry. I think i spoke too soon.
    -There are no security plugins and additionally,
   this is the same site copied over from another host so it has the exact same 
   plugins as the site that works. -I also tried all the different drop down options
   which give the same errors. -The plugin status for all items say good under support.
   See below. -The only thing i could think that’s different are maybe PHP settings?
   Could that have an affect?
 * WordPress REST API Good WordPress REST API is working at [https://www.sfveincenter.com/wp-admin/admin-ajax.php?action=red_proxy&rest_path=](https://www.sfveincenter.com/wp-admin/admin-ajax.php?action=red_proxy&rest_path=)
   
   Redirection routes Good Redirection routes are working Database tables Good All
   tables present Valid groups Good Valid groups detected Valid redirect group Good
   All redirects have a valid group Post monitor group Good Post monitor group is
   valid Site and home protocol Good Site and home are consistent
 *  Thread Starter [jeffeisenberg](https://wordpress.org/support/users/jeffeisenberg/)
 * (@jeffeisenberg)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-10867801)
 * It’s a memory error. I found it in CPanel caused by Ajax. What’s strange is PHP
   allows 512 and WP is asking for 256 and tried 512 so it shouldn’t run out. I 
   may just try a VPS instead.
 * Thanks
 *  [Robey Lawrence](https://wordpress.org/support/users/robey/)
 * (@robey)
 * [7 years, 3 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-11265685)
 * Just wanted to add my scenario here in case it helps anyone else.
 * I was working on a staging copy of a site that I had duplicated to my server.
   I was accessing it via https, however I must have chose to add an exception to
   the browser and I had not installed an SSL on the staging server. This was causing
   a connection point from being blocked due to mixed content.
 * After installing an SSL and reconfiguring the Really Simple SSL plugin, the REST
   API was happily connecting again.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Error re JSON / REST API’ is closed to new replies.

 * ![](https://ps.w.org/redirection/assets/icon-256x256.jpg?rev=983639)
 * [Redirection](https://wordpress.org/plugins/redirection/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/redirection/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/redirection/)
 * [Active Topics](https://wordpress.org/support/plugin/redirection/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/redirection/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/redirection/reviews/)

 * 5 replies
 * 3 participants
 * Last reply from: [Robey Lawrence](https://wordpress.org/support/users/robey/)
 * Last activity: [7 years, 3 months ago](https://wordpress.org/support/topic/error-re-json-rest-api/#post-11265685)
 * Status: resolved