Title: SyntaxError: Unexpected token N
Last modified: April 28, 2018

---

# SyntaxError: Unexpected token N

 *  Resolved [vrpr](https://wordpress.org/support/users/vrpr/)
 * (@vrpr)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/syntaxerror-unexpected-token-n/)
 * Hi,
    I have got next errors when I use “Regenerate Thumbnails” plugin:
 *     ```
       Skipped Attachment ID 346: SyntaxError: Unexpected token N in JSON at position 1
       Skipped Attachment ID 459: SyntaxError: Unexpected token N in JSON at position 1
       Skipped Attachment ID 463: SyntaxError: Unexpected token N in JSON at position 1
       ```
   
 * It was writing about all images.
    It happend for one theme. If I use other themes–
   there is not this error. What it can be?
 * Best regards
    vrpr
    -  This topic was modified 8 years, 4 months ago by [vrpr](https://wordpress.org/support/users/vrpr/).
    -  This topic was modified 8 years, 4 months ago by [vrpr](https://wordpress.org/support/users/vrpr/).
    -  This topic was modified 8 years, 4 months ago by [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/).
      Reason: removed LI
    -  This topic was modified 8 years, 4 months ago by [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/).

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

 *  Thread Starter [vrpr](https://wordpress.org/support/users/vrpr/)
 * (@vrpr)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/syntaxerror-unexpected-token-n/#post-9901470)
 * I wrote not right, I saw this:
 *     ```
       Skipped Attachment ID 513: SyntaxError: Unexpected token < in JSON at position 0
       Skipped Attachment ID 458: SyntaxError: Unexpected token < in JSON at position 0
       Skipped Attachment ID 508: SyntaxError: Unexpected token < in JSON at position 0
       ```
   
    -  This reply was modified 8 years, 4 months ago by [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/).
 *  Thread Starter [vrpr](https://wordpress.org/support/users/vrpr/)
 * (@vrpr)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/syntaxerror-unexpected-token-n/#post-9901742)
 * I found that this error happens after adding retina.js in theme. Maybe I was 
   adding retina.js in not right way.
 *  Plugin Contributor [viper007bond](https://wordpress.org/support/users/viper007bond/)
 * (@viper007bond)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/syntaxerror-unexpected-token-n/#post-9907781)
 * > Maybe I was adding retina.js in not right way.
 * That sounds like the case. If I had to guess, your `<script>` tag was being outputted
   as a part of the JSON response in the REST API.
 * Check out [https://developer.wordpress.org/reference/functions/wp_enqueue_script/](https://developer.wordpress.org/reference/functions/wp_enqueue_script/)

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

The topic ‘SyntaxError: Unexpected token N’ is closed to new replies.

 * ![](https://ps.w.org/regenerate-thumbnails/assets/icon-128x128.png?rev=1753390)
 * [Regenerate Thumbnails](https://wordpress.org/plugins/regenerate-thumbnails/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/regenerate-thumbnails/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/regenerate-thumbnails/)
 * [Active Topics](https://wordpress.org/support/plugin/regenerate-thumbnails/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/regenerate-thumbnails/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/regenerate-thumbnails/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [viper007bond](https://wordpress.org/support/users/viper007bond/)
 * Last activity: [8 years, 4 months ago](https://wordpress.org/support/topic/syntaxerror-unexpected-token-n/#post-9907781)
 * Status: resolved