De nos jours, la plupart des gens utilisent au moins une plateforme de médias sociaux.

Pourquoi intégrer Twitter à WordPress ?

Twitter compte plus de 300 millions d’utilisateurs actifs mensuels et près de 150 millions d’utilisateurs quotidiens, ce qui en fait une excellente plateforme pour toucher de nouveaux clients. De nombreux sites web utilisent également Twitter pour tenir leurs abonnés informés de leurs publications et interagir avec eux.

De nombreux plugins vous permettent de partager automatiquement votre contenu sur Twitter. Cependant,

Comment connecter Twitter à WordPress ?

Il existe plusieurs méthodes pour connecter Twitter à WordPress.

  1. Intégrer des tweets
  2. Extraire le contenu d’un seul tweet/tweetstorm
  3. Flux Twitter
  4. Afficher des tweets spécifiques
  5. Widget de chronologie
  6. Bouton de partage
  7. Bouton Suivre
  8. Tweets
  9. Partage de contenu
  10. Icônes de tweet en ligne
  11. Cartes Twitter

 

1) Intégrer des tweets

La première méthode pour intégrer Twitter à WordPress consiste à intégrer des tweets à votre site. Et le meilleur, c’est que cela ne prend qu’une minute. 

Tout d’abord, recherchez l’URL du tweet que vous souhaitez intégrer à votre site.

Éditeur classique

Si vous utilisez l’éditeur classique, accédez à la page ou à la publication où vous souhaitez insérer le tweet, collez l’URL et enregistrez/mettez à jour la publication.

Connecter Twitter à WordPress – éditeur classique

Après cela, vous verrez le tweet

"tweet

Gutenberg

En revanche, si vous utilisez l’éditeur Gutenberg, après avoir copié l’URL du tweet, recherchez le bloc Twitter, collez l’URL du tweet et publiez la mise à jour.

blocage Twitter

Vous verrez un aperçu en direct sur votre éditeur et la version finale

Connecter Twitter à WordPress – Publication Twitter QuadLayers

Bref et concis, n’est-ce pas ? En moins d’une minute, vous pouvez intégrer n’importe quel tweet sur votre site WordPress et le connecter à Twitter.

2) Extraire le contenu de tweets uniques ou de Tweetstorms

Si vous utilisez la dernière version de l’éditeur Gutenberg, vous pouvez extraire du contenu de Twitter et l’afficher sur votre site grâce au bloc Twitter . Voyons comment procéder.

Tout d’abord, accédez à votre éditeur Gutenberg et ajoutez un bloc Twitter. Saisissez ensuite l’URL du tweet ou du tweetstorm que vous souhaitez y intégrer. Pour cette démonstration, nous allons intégrer l’un de nos tweets.

utiliser le bloc Twitter

 

"tweet

De cette façon, vous pourrez intégrer n’importe quel tweet ou tweetstorm sur votre site en moins d’une minute.

Veuillez noter que cette méthode ne fonctionne que si vous utilisez l’éditeur Gutenberg. 

3) Flux Twitter

C’est une façon très intéressante de connecter Twitter à WordPress, surtout pour les utilisateurs très actifs sur la plateforme.

First, go to the Twitter Publish tool and select the Embedded timeline option. You will need to enter the Twitter profile URL there.

créer une chronologie Twitter

Then, you will see a unique HTML code with a preview of the widget.

aperçu de la chronologie Twitter

So if you want to embed this page on your site, simply copy the HTML code and paste it into the page or post you want. There are two options here:

Classic Editor

If you use the Classic Editor, make sure that you are using the Text Editor when you add HTML to your content.

flux Twitter de l'éditeur classique

Then, simply update the post and the feed will appear on that post.

Gutenberg

If you use Gutenberg, you can use the HTML block to add HTML to your posts.

ajouter un bloc HTML à l'éditeur

After adding the code, update the post and you will see the Twitter feed you’ve just created in the frontend.

We recommend you create a dedicated page for your Twitter feed. The code will pull all your available tweets into the page, so it’ll make posts very long. It’s worth noting that you can include your own Twitter feed and also the feed of others. You just need the Twitter profile URL andyou are good to go.

4) Display Specific Tweets

Sometimes, instead of embedding the entire Twitter profile, you need to embed specific tweets on your site. To do that, go to the Tweet you want to add and click on the three-dotted button in the top right corner. There, you will see the embed option. After you press it, you’ll go to Twitter Publish to get an HTML code.

intégrer une publication Twitter

Copy the HTML code and then go to your WordPress admin. If you use the Gutenberg editor, add an HTML block, paste the code and save the post.

ajouter un bloc html

If, on the other hand, you use the Classic Editor, use the Text mode, and paste the HTML code there.

éditeur classique de collage HTML

After that, you will see the Tweet you have just embedded in your post.

"tweet

5) Add a Twitter Timeline Widget

Another interesting option to connect Twitter with WordPress is to add a timeline to any of your widget areas. This way, customers will be able to see your tweets on any page, post, or wherever you have enabled the widget position.

To add a Twitter timeline widget, go to the Twitter Publish website, choose the Embedded Timeline option, and paste the URL of your Twitter profile.

mini widget Twitter

Then, copy the HTML code.

copier le code HTML du flux Twitter

After that, log in to your WordPress site and go to Appearance > Widgets. There, you will need to add an HTML widget to your right sidebar and paste the HTML code you’ve just copied.

ajouter un widget HTML à la barre latérale

Then, save the changes and you are good to go. Finally, check your website’s sidebar and you will see a responsive Twitter timeline widget there.

"ajouter

It’s worth noting that you don’t need to do anything to make the widget responsive. The code will take care of it.

If you also want to add an Instagram Feed to your site, you can use this free tool whereas to include a Facebook widget to your site, check out this guide.

6) Include a Twitter Sharing Button

Adding a sharing button is a great way to connect Twitter with your WordPress site. Letting your visitors share your content on Twitter will help you reach wider audiences at no cost. To do this, you need a social sharing plugin. Here, we’ll show you how to add a sharing button using two different tools.

6.1) Jetpack/a>

Jetpack is one of the most popular plugins out there and comes with tons of features. To include a sharing button, first, you need to install and activate it on your website.

Connectez Twitter à WordPress - installez le plugin Jetpack

Then, click on the Set Up JetPack button to register your site. You will need a Google or WordPress.com account to complete the authentication.

JetPack is a freemium solution and you can add sharing buttons using the free version. To do so, go to the Jetpack settings and then to the Sharing tab. There, simply activate the Enable social sharing buttons.

Connect Twitter with WordPress - enable jetpack plugin's social sharing feature

Now, let’s configure the sharing buttons by pressing the corresponding link.

Connect Twitter with WordPress - configure jetpack sharing buttons

This will redirect you to the WordPress.com site. Under Marketing & Integrations, you will see the social sharing settings.

jetpack sharing button settings

From there, you can configure your Social Sharing buttons. Once you’re happy with the changes, save them and you are good to go. Now, the social buttons will appear on your site posts.

For more information about Jetpack’s features and pricing, check out our complete JetPack guide.

6.2) Social Snap Lite

Social Snap is another excellent tool to add social buttons to your site. It has both a free version and premium plans. For this demo, we’ll use the free plan.

First, install and activate Social Snap on your website.

Connect Twitter with WordPress - add social snap lite plugin

After that, you will see the plugin’s settings. Click on the Customize Social Snap button.

Connect Twitter with WordPress - social snap plugin settings

Then, you will see a customization page like this:

Connect Twitter with WordPress - social snap settings

The plugin adds a Twitter share icon by default and you can add other social networks from the Network settings.

Connect Twitter with WordPress - add new social media icons

Additionally, you can include a floating sidebar on your site. And the good thing is that just like we’ve seen how to make the Divi header or any other element sticky, these social share buttons will be fixed.Connect Twitter with WordPress - add social snap floating widget

Apart from choosing which social media buttons you want to display, you can add some customization. From the Inline settings, you can change the position, label, button shape and size, and so on.

Connect Twitter with WordPress - social snap inline settings

After you finish the customization, save the changes.

save social snap settings

Finally, check your site from the frontend and you will see the social sharing buttons.

Connect Twitter with WordPress - social share buttons of social snap lite

7) Add a Twitter Follow Button

Apart from adding sharing buttons, another excellent way to connect Twitter with your WordPress site is to include a follow button. This way, your visitors will be able to follow you directly from your website.

Adding a follow button is very easy and doesn’t require any plugins. First, go to Twitter Publish and under the Twitter Buttons, you will see an option to include a follow button.

add a twitter follow button

You need to enter your Twitter URL and press Preview.

twitter button previewing

Then, you’ll be able to copy a unique HTML code. We’re going to leave the default styling but you can check out the customization options if you need to apply some changes to your button.

twitter follow button customization

Now, let’s see how to add this button to your site using both the Classic Editor and the Gutenberg editor.

Classic Editor

If you are using the Classic Editor, go to the text mode of the post/page where you want to include the button and paste the HTML code in a new line.

classic editor html editor

After that, publish/update the post and you will see the change in the frontend.

classic editor follow button

Gutenberg Editor

If you use the Gutenberg editor, simply add an HTML block, and paste the HTML code in the post/page you want to include the button.

add gutenberg html editor follow button

Then check the frontend and you will see the Follow button.

follow button Twitter

Additionally, you can also add this HTML code to your website’s sidebar or footer.

8) Display Tweets on the Sidebar

The sidebars are very helpful when you run content-rich or news websites. And the good thing is that most WordPress themes like GeneratePress, Divi, or Avada allow users to customize the sidebar.

Adding a Twitter widget to your sidebar is an excellent option to display information to your users. So, in this section, we will show you how to display tweets on the sidebar without installing any plugins.

First, go to your WordPress dashboard > Appearance > Widgets.

all wordpress widgets

You will see all the available widgets and positions there. For example, on our site, we have several widget positions.

all widget areas

For this demonstration, we’ll add a new text widget to the right sidebar section.

connect twitter with wordpress - add text widget to sidebar

Then, you have to name the widget and paste the Twitter profile’s URL in the content section. You can find the URL from your browser’s address bar. In our case, we are going to use our Twitter handle’s URL.

connect twitter with wordpress - QuadLayers twitter handle

So, after modifying our new text widget, it will look like this:

connect twitter with wordpress - paste twitter URL to sidebar widget

As you can see, WordPress automatically converts the URL to a scrollable Twitter feed. Finally, save the widget and check your website’s frontend to see the result.

connect twitter with wordpress - sidebar twitter feed

9) Share Your Content on Twitter

Sharing your WordPress content on Twitter is an excellent option to integrate both platforms and get extra social traffic to your site. Doing this manually takes time and it’s not a good option if you regularly publish content on your site. However, there’s a solution for that.

In this section, we will show you the Twitter standard sharing method and the new Tweetstorm feature. Keep in mind that you will need Jetpack installed and set up. If you’re not sure how to do that, check this out.

9.1) Standard Sharing Method

Once you finish the article you want to share, go to the Jetpack settings.

jetpack button on editor

Then, connect your Twitter account.

connect twitter account

Here, you will also be able to connect other social media accounts such as Facebook, LinkedIn, and so on.

twitter account

After connecting your Twitter account, you will see an option for sharing your post to the Twitter account as a link. That’s the standard sharing.

jetpack standard sharing

Now, let’s have a look at the tweetstorm method.

9.2) TweetstormMethod

If instead of sharing your content as a link you want to publish the whole post as a Twitter thread, simply select the second option.

tweetstorm post

Setting this up on your WordPress site will help you save some time. You won’t need to log in to Twitter every time you want to share something. With this, when you publish a post, it will be automatically shared on all your linked social media profiles.

10) Add Inline Tweet Icons

When you share some important news, it’s a good idea to add inline tweet icons to your posts. By default, WordPress doesn’t include this feature but you can easily add a tweet button to your content with the Inline Tweet Sharer plugin. Let’s see how to do it.

First, install and activate Inline Tweet Sharer on your site.

Connect Twitter with WordPress - install inline twitter sharer plugin

Then, go to the plugin’s settings under the WordPress settings section.

Connect Twitter with WordPress - inline tweet sharer plugin settings

There, you can enter your Twitter username and select other options but it’s optional.

Connect Twitter with WordPress - default twitter username

After that, you can add the Tweet icon using a shortcode in the WordPress editor. The shortcode we are going to use is [inlinetweet]. For example, check out the screenshot we have below.

Connect Twitter with WordPress - add tweetable content

If you check the post from the frontend, you will see the Tweetable text which will be a link.

Connect Twitter with WordPress - tweetable content

When you click on it, your browser will open the Twitter site and from there, you will be able to share it on Twitter.

Connect Twitter with WordPress - tweet text

11) Add Twitter Cards

Finally, the last method to connect Twitter with WordPress is via cards. In this section, we are going to show you how to create a Twitter card using two free plugins: Yoast SEO and JM Twitter Cards.

11.1) Add Twitter Cards with Yoast SEO

If you have already installed and configured Yoast SEO, feel free to skip the installation and basic configuration settings. If you are new to Yoast, install it, and activate it from the WordPress plugins repository.

Connect Twitter with WordPress - install yoast seo plugin

After that, go to Yoast SEO’s Social section.

Connect Twitter with WordPress - twitter social tab

There, you will be able to enter your Twitter username.

Connect Twitter with WordPress - twitter username

After saving the changes, under the Twitter section, you will see the Twitter Card configuration. Make sure that you enable it.

Connect Twitter with WordPress - yoast twitter settings

Then, go to the Users’ settings and add your Twitter username.

Connect Twitter with WordPress - wordpress profile settings

That’s it! Now, when someone tweets your posts on Twitter, they will see a card.

Yoast SEO is just one of the SEO plugins out there. If you’re using other tools such as Rank Math SEO or All In One SEO Pack, you’ll need an additional plugin to include Twitter cards on your website. Let’s see how to do it with JM Twitter Cards.

11.2) Ajouter des cartes Twitter avec JM Twitter Cards

JM Twitter Cards est un excellent plugin gratuit pour ajouter des cartes Twitter. 

Après avoir installé l’extension sur votre site WordPress, accédez à ses paramètres. Saisissez votre nom d’utilisateur Twitter et celui de votre entreprise, puis configurez le type de carte que vous souhaitez afficher.

jm twitter cards plugin settings

Enregistrez ensuite les paramètres et c’est parti. Désormais, lorsque quelqu’un partagera votre publication sur Twitter, il verra la carte Twitter.

Conclusion

En résumé, intégrer Twitter à votre site est un excellent moyen d’améliorer votre présence sur les réseaux sociaux et d’atteindre davantage de clients.

    • Intégrer des tweets
  • Extraire le contenu d’un seul tweet/tweetstorm
  • Flux Twitter
  • Afficher des tweets spécifiques
  • Widgetde chronologie
  • Bouton de partage
  • Bouton Suivre
  • Tweets
  • Partage de contenu
  • Icônes de tweet en ligne
  • Cartes Twitter

Toutes ces méthodes sont très faciles à mettre en œuvre ; choisissez celle qui correspond le mieux à vos besoins. Si vous utilisez un site WordPress riche en contenu, vous pouvez ajouter des boutons de partage social à vos publications en quelques clics grâce à Jetpack ou Social Snap.

En revanche, si vous êtes très actif sur Twitter, créer une mini-page Twitter sur votre site est une excellente option. Ainsi, les utilisateurs pourront accéder à tout le contenu de votre site et augmenter ainsi le temps passé sur la page. De plus, ajouter un bouton « S’abonner » et des options de partage de contenu sur votre site est indispensable.

Enfin, si vous souhaitez intégrer vos comptes de réseaux sociaux à votre site, consultez ces guides :

  • Comment ajouter le widget Facebook à WordPress ?
  • Galerie de flux Instagram : le meilleur plugin Instagram pour WordPress

Connaissez-vous d’autres méthodes pour connecter Twitter à WordPress ? Laquelle préférez-vous ? Dites-le-nous