Themewaves
How-To

How Do You Add a Twitter Feed to WordPress?

Add a Twitter feed or post to WordPress, then tune its look and fix common issues.

How Do You Add a Twitter Feed to WordPress?

Understanding Twitter Feeds

A Twitter feed shows public posts from an X account on another site. X was called Twitter, so many WordPress users still search for Twitter embeds. A timeline can show recent posts from one account. A post embed shows one selected post.

The embed loads content from X rather than saving a copy in WordPress. This means the post can change or vanish if its owner deletes it. A private account will not show its timeline to everyone. Visitors also need a working connection to load the feed.

Pick the format that fits the page. A timeline may suit a news page or blog sidebar. A single post can support an article about that post's topic. Use a feed where it adds context, not on every page.

That keeps the page focused.

Benefits of Adding Twitter to WordPress

A feed can show fresh updates between changes to your site. It can also help visitors find your social account and join a discussion. For example, a local shop could show product news beside a related blog post.

Social content should not hold key details. Some visitors block social embeds, and others may have slow connections. Keep important news, hours, and offers on your own site. Treat the feed as an extra source of updates.

Good placement helps. Put a feed near content it supports. Check the layout on phones and desktop screens. A narrow sidebar can cut off posts or crowd the page.

Relevance matters more than reach.

How to Get Twitter Widget Code

To learn how to add Twitter feed to WordPress, first get the embed code from X. Open X's publish tool and enter the address of a public profile or post. The tool then offers an embed for that content.

For a timeline, copy the profile address, such as x.com/example. Paste it into the tool and choose the timeline option. For one post, open that post and copy its address instead. Check that the post or account is public.

  1. Open the X publish tool.
  2. Paste the full profile or post address.
  3. Choose a timeline or post embed.
  4. Set any options the tool offers.
  5. Copy the full code it creates.

The code may include a link and a script. Keep both parts together. If the tool offers a height or theme setting, choose it before copying. You can check the result in WordPress before publishing.

That is the first key step.

Embedding a Twitter Feed Manually

To learn how to embed a Twitter feed in WordPress, use a Custom HTML block. Edit the page or post where the feed should appear. Add the block, paste the full code, and preview the result.

To learn how to embed Twitter feed on WordPress in a sidebar or footer, open your theme's widget area or site editor. Add a Custom HTML block there, then paste the same code. Menu names can vary by theme and WordPress version.

  1. Open the page, post, or widget area.
  2. Add a Custom HTML block.
  3. Paste the full embed code without removing its script.
  4. Preview the page on desktop and mobile.
  5. Publish or update the page when it looks right.

To learn how to embed Twitter post in WordPress, follow the same steps with code for one public post. Do not paste the code into a Paragraph block. If WordPress removes the script, your role or site settings may block it. Ask your site administrator to check permissions, or use a trusted plugin.

Check the page before you share it.

Using a Plugin to Add a Twitter Feed

A plugin can help if you need more layout choices or several feeds. Plugin features and names can change, so review the current listing, update date, support notes, and user feedback. Install one feed plugin unless you have a clear reason to use more.

  • Custom Twitter Feeds by Smash Balloon: Offers feed layouts and style settings. Some features may need a paid plan or current access to X.
  • Jetpack: Provides social tools as part of a wider set of site features. Check its current support for the type of feed you need.
  • EmbedSocial: Offers tools for feeds from supported social networks. Check which features need an account or paid plan.

To start, open Plugins in your WordPress dashboard and choose Add New. Search for the exact plugin name, review its details, then install and activate it. Follow its setup steps to link an account or add a feed address.

Some plugins need X access or an API key. Follow the plugin maker's current setup steps. Never place a secret key on a public page. Once the feed is set up, add its block or shortcode and test the page.

Use the plugin's own setup notes.

Customizing Your Twitter Feed

Choose a space wide enough for post text and controls. A main content column often works better than a narrow sidebar. Set a useful height, and avoid showing more posts than readers need.

Match the feed to your site's style. A simple border or background can help it feel at home. Keep contrast strong and avoid design choices that make post text hard to read. If the plugin has theme settings, preview each choice before saving.

Responsive design matters. Check the feed on a phone, tablet, and desktop screen. Look for cut-off text, sideways scrolling, or controls that overlap. If the feed feels cramped, make it wider or show fewer posts.

Small changes can improve the whole page.

Crimson panel and dark device in a clean workspace, evoking a well-styled social feed layout
A clean layout for a social feed

Troubleshooting Common Issues

If the feed does not appear, check the source first. Confirm that the profile or post is public and that its address is correct. Then make sure you pasted the full code, including any script, into a Custom HTML block.

If the code disappears after saving, your account role or security settings may block scripts. Ask an administrator to review the setting. A plugin may be a better fit if you cannot add scripts by hand.

  • Blank feed: Check the page in a private browser window and confirm the post is still public.
  • Code shows as plain text: Move it from a Paragraph block to a Custom HTML block.
  • Feed looks cut off: Increase its height or place it in a wider area.
  • Feed loads slowly: Show fewer posts and remove any extra feed plugins.
  • Plugin stops working: Check for updates and read the maker's current support notes.

Test the page after each change. This makes it easier to spot the cause. If a plugin handles the feed, check its connection settings and any access steps from its maker.

Retest on both phone and desktop.

Choose the Right Way to Add a Feed

For a single public post, a manual embed can be quick and simple. A timeline may take more room, so test its height and width before publishing. If you need style controls or several feeds, a plugin may save time.

In short, how to add Twitter to WordPress depends on the page and the feed you want. The manual method gives you direct control over the embed code. A plugin can offer more layout tools, but it adds another item to maintain.

Keep the feed useful, readable, and easy to load. Check it again when your theme, plugin, or X settings change. That helps visitors get the intended content without making the page harder to use.

Red folder beside a dark tablet on a white surface, suggesting a choice of WordPress feed tools
Choosing a WordPress feed setup

Step-by-step

  1. 01
    Get the embed code

    Open X's publish tool and enter a public profile or post address. Choose the embed type and copy the full code.

  2. 02
    Add a Custom HTML block

    Edit the WordPress page, post, or widget area. Add a Custom HTML block where the feed should appear.

  3. 03
    Paste and preview

    Paste the full code into the block. Preview the page on desktop and mobile, then publish it when the feed looks right.

Frequently asked questions

How do I add a Twitter feed to WordPress?
Get the embed code for a public profile from X's publish tool. Paste it into a Custom HTML block, then preview the page.
How do I embed a Twitter post in WordPress?
Copy the address of a public post into X's publish tool. Paste the code it creates into a Custom HTML block.
Why is my Twitter feed not showing in WordPress?
Check that the account or post is public and that the embed code is complete. WordPress settings may also block scripts for your account role.
Can I add a Twitter feed to a WordPress sidebar?
Yes. Add a Custom HTML block in your theme's widget area or site editor, then paste the feed code.
Should I use a plugin or embed code for a Twitter feed?
Embed code works well for a basic timeline or one post. A plugin may suit you better if you need more layout controls or several feeds.
Share XFacebookWhatsApp

Related reading

About cookies on this site

Essential cookies keep pages loading and the enquiry form working. Anything beyond that is optional and we only set it if you say yes. Details live in our Cookie Policy.