Title: Fatal error: Call to undefined function wp_json_encode()
Last modified: August 30, 2016

---

# Fatal error: Call to undefined function wp_json_encode()

 *  [CeliaDD](https://wordpress.org/support/users/celiadd/)
 * (@celiadd)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_json_encode-2/)
 * Hi!
 * I am having problems trying to access to my site. This is the message:
 * Fatal error: Call to undefined function wp_json_encode() in /usr/home/doordresserblog.
   com/web/wp-includes/class.wp-scripts.php on line 186
 * I have downloaded the file class.wp-scripts.php but I don’t really know what 
   I have to do with it.
 * Could you help me please?
 * Thank you!

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

 *  [Will Schmierer](https://wordpress.org/support/users/officialwill/)
 * (@officialwill)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_json_encode-2/#post-6661105)
 * Celia,
 * It’s likely not an issue with that file directly, and you will most definitely
   not want to modify that file. Is there a plugin that you added or other code 
   you modified before getting that error? It could be a couple of different things,
   but if you have more details that would help pin point the issue a little further.
   Thanks.
 * Will
 *  Thread Starter [CeliaDD](https://wordpress.org/support/users/celiadd/)
 * (@celiadd)
 * [10 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_json_encode-2/#post-6661119)
 * Hi Will,
 * Thanks for your answer.
 * I have not accessed to the site since a long time, so I have not modified anything.
 * The only thing is that we are changing the hosting… Could that be the problem?
 * Thanks again!

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

The topic ‘Fatal error: Call to undefined function wp_json_encode()’ is closed to
new replies.

## Tags

 * [fatal error](https://wordpress.org/support/topic-tag/fatal-error/)
 * [wp_json_encode](https://wordpress.org/support/topic-tag/wp_json_encode/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [CeliaDD](https://wordpress.org/support/users/celiadd/)
 * Last activity: [10 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_json_encode-2/#post-6661119)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
