You can postpone the wp_autop filter. WordPress has this filter enabled by default. And it is processing before the shortcode output.
remove_filter( 'the_content', 'wpautop' );
add_filter( 'the_content', 'wpautop' , 12);
Add this to your functions.php
and check if the problem persist!
See a similar problem here: stray <p> elements
Related Posts:
- Stop WordPress Wrapping Images In A “P” Tag
- Keyboard shortcut for updating a page or post?
- Allow user to “edit_others_posts” to save only, not publish
- how to limit edit_form_after_title hook to page and post edit only?
- disable WP automatically inserted line breaks after an image
- Listen to Post action
- How to create WP Editor using javascript
- How to add editor’s name to entry meta byline?
- Update all posts automatically when using post_meta
- Search & Remove Specific Shortcode From All Posts
- Shortcode Not displayed at the Right Place [duplicate]
- Change padding to text indent in “Increase indent” TinyMCE
- How can I allow editors to leave comments on posts that have not yet been published?
- Specific loop in Shortcode
- Custom function for “Submit for Review” hook
- Content editor creating blank paragraphs in spaces and creating   in the_excerpt
- How To Add Perfect Apostrophe And Quotation Mark In WordPress Posts?
- Adding variable for post title so post template can include auto-generated link to view on external website.com/{post title}
- 2nd button row from WP Super Edit or TinyMCE Advanced doesn’t show to 2nd admin
- Hide Post comments when displayed via WP_Query
- Strange problems when I try to insert HTML\XML code snippet in my posts
- How can I add a meta-box to the posts editor containing all items of a custom taxonomy as checkbox?
- Remove Shortcode […] from Blog Preview
- Visual / HTML tabs vanished on editor
- Getting a 404 error when clicking edit page
- UberMenu list current user’s posts as menu items
- WordPress version 3.8 – Preview button not working for editor
- Number format for wp_count_posts()
- Make Post Editor Select Number of Columns To 1 By Default
- do_shortcode within post query
- Unautop / Sanitize content added to a post through a plugin
- How to get rid of shortcodes in post content once and for all
- get_the_content(“more…”) returns full text
- Is there a straight-forward way to iterate over all shortcodes in a post?
- Format the Layout of Images In The Edit Post Textarea?
- How can i display gallery shortcode output under Post text
- How to display Common posts from specific Tag & Category with Shortcode
- Lost draft under all posts and drafts
- What’s the best way to render Visual Composer in posts, not pages?
- Posting blog entries in screenplay format
- display-posts shortcode attributes have no effect
- Shortcode to display the latest news article within a page
- Shortcodes on my website stops working after theme update [closed]
- How to get ID of the page included with get_page()?
- How to get a post’s details by shortcode?
- WP text styles not coming through to actual post
- WordPress.com post editor replacement
- Shortcode with ‘year’ parameter
- Is it possible to add a shortcode below post title?
- WordPress 302 Redirect to Random Product/Post/Page
- Why can’t publish posts with too much text?
- How to convert query sql to shortcode in wordpress?
- How can I add 2 buttons with shortcode
- Why aren’t paragraphs breaking on this page?
- HTML Inside of Shortcode Breaks Shortcode Output
- Shortcode for tables which can include comma and linebreaks
- post/page content
- Pasting formatted text from MS-Word
- Keyboard shortcut for headings on safari
- All images on one line for each post
- any way to access variables from within post editor?
- Change published date and time using SQL query for page in every 5 hour
- What parameters do I need to pass to get_tags to get ALL tags for the site, when used in a post
- Shortcode for Comments and Comment Boxes in Post Loop
- get category in list of posts // shortcode for custom related posts
- Display “no post” message
- How can I create a shortcode to show the number of posts of actual day?
- Embedding Post Editor Into External Site
- How can I change the date format of the revision list?
- Featured Story Shortcode not outputting content
- Function is printing twice – any suggestions?
- Contact Form 7 Shortcode not recognized inside another shortcode
- Contributor edits published post and sends for review – post is made private?
- Display simple html code in post
- Add a url parameter to the current post and read it in a shortcode
- Secretly passing post ID/title etc into a shortcode form automatically to link submission to post
- I need show posts by customer (Shortcode)
- How to allow some visitors to edit inline specific post
- Post formatting bug in WordPress
- Is it possible to query a category with specified posts?
- Shortcode: How to add custom posts?
- Theme does not respect spaces between paragraphs in pages
- Add category attribute to custom recent post shortcode
- Shortcode for printing post titles
- How to use extract shortcode in loop?
- Using Post ID and Page ID in same function
- How to custom sort-out editing-panel fields?
- Display only posts with comments
- Change the default video URL in a post to shortcode format
- Stripping tag from elements in post
- How do I add an article to specific page?
- get value from post to sidebar
- WordPress Yoast SEO plugin Post Save/Update Issue
- If post has non-shortcode string
- Insert Shortcode exactly at the end of the content
- Trying to create shortcode listing custom posts, but formating not being included
- Show Title/Date/Excerpt of first post & only Title for rest in Query [duplicate]
- Simple shortcode to check if a user has commented on a certain post
- Undefined Function Fatal Error with Shortcode [closed]
- How to use shortcode to get the second to newest post?