Embedding Tweets on Your WordPress Blog

Today at the Realtime Report we developed a WordPress plugin to embed Tweets using the Twitter API.  Like this:

[tweet https://twitter.com/OnionSports/status/145262716104351747]

I know that a plugin is available for WordPress.com sites, but I couldn’t find one for self-hosted WordPress.  I’m working on uploading our plugin to the WordPress.org repository — in the meantime you can download it here: Modern Media Tweet Shortcode. Update: we’ve uploaded it to the WordPress plugins site. Please download it there.

Instructions are below. Let me know @chriscarson if you like it.  Enjoy!

Installing the WordPress plugin

  1. Download and unzip the files.
  2. Upload the ModernMediaTweetShortcode modern-media-tweet-shortcode folder to your site’s wp-content/plugins directory.
  3. Activate the plugin.
  4. Go to the plugin’s settings page: Settings > Embedded Tweets. You may have to check off an option to include a javascript from Twitter. There are a couple of other fun options, like Chinese…

Embedding a Tweet — New Interface

These instructions are for the new web interface Twitter rolled out recently.  If you still have the old interface, scroll down.

From the timeline, click “Open” to show more options.

Click “Details” to go to the Tweet’s unique URL.

Click “Embed This Tweet”…

Click the “Shortcode” tab and copy the URL.

Edit your post.  Paste in the shortcode. It should look something  like this:

[[tweet https://twitter.com/OnionSports/status/145262716104351747]]

Click save and view the post.  Your embedded tweet should show up nicely:

Embedding a Tweet — Old Interface

If you don’t have the new interface yet (I don’t either — I had to hack a colleague’s account to take the screenshots above,)  here’s how you get the unique Tweet URL.

Click on the “sent” link from your timeline…

Copy the URL of the tweet…

You’ll have to type in the shortcode yourself.  The format is…

[[tweet theURLyouCopiedHere]]


  1. @bestofzsazsa ha – awesome – I *just* signed your holiday card! you’ll see it next week & thx for the RT! – Tonia :-)

  2. @cdcarson@ChrisCarson I’ve always wanted to be a bunny! I’m currently swamped by it is on my list for this weekend. I’ll let you know!!

  3. Hi, I’ve been searching for a way to embed only latest tweet… rather than specifying a tweet ID…. Am I missing something?

  4. @PaulDoyleThat’s a different thing. Our plugin is for embedding individual tweets as “quotes” in posts, not the latest tweet from a user. You can probably use Twitter’s own widget — https://twitter.com/about/resources/widgets — in a WordPress text widget in your sidebar. Just paste in the code that Twitter gives you. Hope that helps — Chris

  5. @cdcarson@PaulDoyle Hi Chris, many thanks for your response. Yes I think you’re….

    It’s a pity that the widget doesn’t offer the nicer interface and layout of the web intents version…

  6. @PaulDoyle I agree. It would be relatively easy to do as long as you are interested in displaying one “latest” tweet from one user. I’m fleeing the country for the holidays, but will see what I can do when I get back. In the meantime someone else might have developed what you want. Have you searched the plugins repository?

  7. @cdcarson Yeah I’ve tried a few different plugins and they all provide “some” of the functionality I’m looking for but none provide it all. http://wordpress.org/extend/plugins/twitter-blackbird-pie/ was the closest which does pretty much what you have outline in your article… but only for specific tweets….

    I think I’m going to go with the Twitter widget you pointed me to and just CSS the hell out of it :-). … many thanks for your help. Enjoy you country fleeing holiday ;-)


Please enter your comment!
Please enter your name here