How to Add Featured Image to WordPress RSS Feed Without Plugin?

RSS Stands for Really Simple Syndication. Basically, RSS is used for different purposes. RSS Feed is used by millions of users to track their favorite website. Developers use it to send the latest post as the newsletter to their users using different platforms like MailChimp, Aweber etc.

Generally, People save the web content from the respective website to Feed Reader like Feedly, Inoreader etc. to read it later and in organized form and get the latest update from the blog where they have subscribed from. Normally, website feed is like www.wplogout.com/feed or www.wplogout.com/rss

RSS Feed with Images Example

So, Let’s go to the step to add featured image in RSS Feed

Step 1: Go to your Dashboard (yoursite.com/dashboard)

Step 2: Go to Appearance > Editor

Custom Code to Add Featured Image to WordPress RSS Feed Without Plugin using Editor
Appearance>Editor

Step 3: Select the functions.php and open it

Step 4: Please Backup your functions.php code into text editors like Notepad, Notepad++, Brackets or any IDE you like. If in case your code doesn’t work then you can paste the previous code.

Step 5: Go to the bottom of the functions.php and paste the following code and save it.
Step 6: Before Posting any code, don’t forget to do comment usually starting with // just below in the image so that it will be easier for future preferences.

// Custom Code featured image thumbnails in WordPress RSS Feeds
function wplogout_post_thumbnails_in_feeds( $content ) {
    global $post;
    if( has_post_thumbnail( $post->ID ) ) {
        $content = '<p>' . get_the_post_thumbnail( $post->ID ) . '</p>' . $content;
    }
    return $content;
}
add_filter( 'the_excerpt_rss', 'wplogout_post_thumbnails_in_feeds' );
add_filter( 'the_content_feed', 'wplogout_post_thumbnails_in_feeds' );

Step 7: Test whether this code and your feed are working or not. To check please visit RSS Preview Web sites like Feedbucket or CodeRedCorp. It will display the featured image in RSS feed as below.

I have tested this above code in Genesis Theme where this code works perfectly. I have used this code to Add Featured Image to MailChimp RSS to Email with Post Summary while sending the newsletter to the subscribed users.

If your and Non-technical user than you can follow this tutorial using Plugin.

Recommend: How to Add Featured Image to WordPress RSS Feed Using Plugin?

If you have any problem regarding adding images to RSS feed then feel free to comments below.

Get 100+ FREE SEO TOOLS

Quickly access over 100+ popular SEO,
Marketing tools to boost your website traffic.

Thank you for subscribing. Check your Email (Didn't receive? check spam folder)

Something went wrong.

I love all things having to do with WordPress, Digital Marketing, Social Media. Blogging has been my Passion. I'm interested in Literature and sometimes, loves to write.

Leave a Comment

Download Brave Browser with AdblockerInstall Brave Now
+ +