JM Twitter Cards


Once activated the plugin adds appropriate meta on your WordPress website allowing you to get Twitter cards for your posts according to your settings. Enjoy !


  • Gutenberg compatible with a custom sidebar
  • meta box : customize Twitter Cards experience (per each post)
  • preview : preview the rendering on Twitter.
  • WP SEO by Yoast and All in One SEO compatible (no conflict with SEO title and desc set with these plugins)

First image found instead of featured image

If you want to get first image found in post content as twitter image, I’ve created a free add-on here

Force refresh Twitter image

If you want to get your Twitter image to refresh, I’ve created a free add-on here


The plugin is available in French, English and Spanish. Feel totally free to send me your translation in other languages.
You’ll be added to the list here with your name and URL.
Thanks a lot to all translators. Can’t wait to add your work to the project.


This URL is the place where I improve the plugin according to support requests and stuffs like this. GitHub is the place !


  1. Upload plugin files to the /wp-content/plugins/ directory
  2. Activate the plugin through the Plugins menu in WordPress
  3. Then go to settings > JM Twitter Cards to configure the plugin
  4. To display the metabox in edit section (posts, pages, attachments) just use default settings or enable only the post types you want


I got problem with Instagram

It’s a known issue due to Instagram. Twitter said it recently : Users are experiencing issues with viewing Instagram photos on Twitter. Issues include cropped images.This is due to Instagram disabling its Twitter cards integration, and as a result, photos are being displayed using a pre-cards experience.
So, when users click on Tweets with an Instagram link, photos appear cropped.

Plugin is fine but Twitter cards doesn’t appear in my tweets

  1. Make sure you correctly fulfilled fields in option page according to Twitter documentation
  2. Be careful with your robots.txt and put some rules to allow Twitter to fetch your website :

    User-agent: Twitterbot

If it still doesn’t work please open a thread on support.

The plugin generates a lot of images (different sizes)

I can be a problem when you work with HD and/or a lot of images.

How do I use the custom fields option?

Basically you provide your custom field keys in plugin option page and then it will grab datas.

* *
* En Français *
* *

Problème avec Instagram

C’est un problème connu. Cela vient d’Instagram lui-même qui préfère que ses utilisateurs partagent les photos chez lui plutôt que sur Twitter. Instagram a supprimé ses Twitter Cards.

Le plugin marche mais je n’obtiens pas de Twitter Cards dans mes tweets

  1. Assurez-vous bien d’avoir rempli correctement les champs dans la page d’options suivant la documentation Twitter
  2. Attention avec le fichier robots.txt, vous devez autoriser le robot de Twitter à crawler votre site:

    User-agent: Twitterbot

Si cela ne marche toujours pas SVP ouvrez un topic sur le support.

Le plugin génère beaucoup trop de fichiers images

Cela peut poser problème si vous travaillez avec de la HD et/ou beaucoup d’images. Vous pouvez donc utiliser un plugin qui va effacer les fichiers images non utilisés.

Comment utiliser l’option custom fields?

Il suffit de renseigner les clés de vos custom fields en page d’option et le plugin s’occupera de récupérer les datas correspondantes.


11 January 2018
Not compatible with the latest version of WordPress. It breaks the website entirely.
30 October 2017
I've been using this for a wee while now and I love it. It's super easy to set up, and the results look great. I don't do well with complicated things but I was able to get it working. The Dev is quick to respond to issues and fix problems.
9 October 2017
This plugin is no longer working! When I attempt to change to a new twitter card, it keeps showing the old photo. Disappointed!
Read all 48 reviews

Contributors & Developers

“JM Twitter Cards” is open source software. The following people have contributed to this plugin.


Translate “JM Twitter Cards” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Change log


  • September 2020
  • update dependencies
  • refactoring


  • July 2020
  • update dependencies
  • refactoring
  • use yarn


  • September 2019
  • update dependencies


  • December 2018
  • handle case where installation is WordPress 5++ but the classic editor plugin or the disable Gutenberg plugin is used


  • December 2018
  • Reorganize deeply the plugin structure
  • css fixes props to tomdxw
  • delete image sizes, actually very bad for disk space and rules have changes in 2018 with Twitter image
  • Gutenberg users will have additional features such as custom modal and preview but also custom title and desc for cards \0/
  • I’ve added some instructions and advices props to
  • There is a new admin sub page called “tutorials” with video tutorials !


  • June 2018
  • remove bad bad method get_keys()
  • remove preview js so now you’ll have to save post as draft or publish to see preview, need to prepare for Gutenberg
  • refactor code
  • fix images sizes never added (don’t forget to regenerate thumbnails)
  • remove deprecated code (PHP 7.2)


  • April 2018
  • fix bug wrong ternaries in class options (props @ioneill)
  • fix sanitize metabox card type not taking into account app card


  • Feb 2018
  • fix error in about.php
  • fix warnings in case very first use
  • remove get_keys() cause slow on large site, this feature is useless for now
  • fix incompatibility with NGG (nextgen gallery)


  • Jan 2018
  • multiple js bugfixes especially in preview
  • reorganize + enhance code, this is a major release but it won’t break anything, filters are still there
  • add twitter meta image alt
  • add new dropdown menu to select custom meta key (advanced users).


  • 30 Oct 2017
  • fix markup issue that causes setting error
  • fix bug first page not saving options anymore


  • 28 Oct 2017
  • fix admin screens & reported incompatibilities with themes
  • delete crappy localstorage


  • 09 Sept 2017
  • test up compat to WordPress 4.8.1
  • fix display cars according to post types options
  • fix missing loading class
  • fix empty description when excerpt option is on and there’s no excerpt